[asterisk-commits] mattf: trunk r91012 - /trunk/channels/chan_zap.c

SVN commits to the Asterisk project asterisk-commits at lists.digium.com
Tue Dec 4 16:44:02 CST 2007


Author: mattf
Date: Tue Dec  4 16:44:01 2007
New Revision: 91012

URL: http://svn.digium.com/view/asterisk?view=rev&rev=91012
Log:
Don't error when we don't have libpri installed with libss7 support.  Also, print the debug message anyway if we can't find the right PRI

Modified:
    trunk/channels/chan_zap.c

Modified: trunk/channels/chan_zap.c
URL: http://svn.digium.com/view/asterisk/trunk/channels/chan_zap.c?view=diff&rev=91012&r1=91011&r2=91012
==============================================================================
--- trunk/channels/chan_zap.c (original)
+++ trunk/channels/chan_zap.c Tue Dec  4 16:44:01 2007
@@ -5861,7 +5861,7 @@
 #if defined(HAVE_PRI)
 	tmp->transfercapability = transfercapability;
 	pbx_builtin_setvar_helper(tmp, "TRANSFERCAPABILITY", ast_transfercapability2str(transfercapability));
-	if (transfercapability & PRI_TRANS_CAP_DIGITAL)
+	if (transfercapability & AST_TRANS_CAP_DIGITAL)
 		i->digital = 1;
 	/* Assume calls are not idle calls unless we're told differently */
 	i->isidlecall = 0;
@@ -9538,13 +9538,10 @@
 			}
 			dchancount = 0;
 		}
-		if ((dchan >= 0) && (span >= 0)) {
-			if (dchancount > 1)
-				ast_verbose("[Span %d D-Channel %d]%s", span, dchan, s);
-			else
-				ast_verbose("%s", s);
-		} else
-			ast_log(LOG_ERROR, "PRI debug error: could not find pri associated it with debug message output\n");
+		if (dchancount > 1 && (span > -1))
+			ast_verbose("[Span %d D-Channel %d]%s", span, dchan, s);
+		else
+			ast_verbose("%s", s);
 	} else
 		ast_verbose("%s", s);
 
@@ -9577,13 +9574,10 @@
 			}
 			dchancount = 0;
 		}
-		if ((dchan >= 0) && (span >= 0)) {
-			if (dchancount > 1)
-				ast_log(LOG_ERROR, "[Span %d D-Channel %d] PRI: %s", span, dchan, s);
-			else
-				ast_log(LOG_ERROR, "%s", s);
-		} else
-			ast_log(LOG_ERROR, "PRI debug error: could not find pri associated it with debug message output\n");
+		if ((dchancount > 1) && (span > -1))
+			ast_log(LOG_ERROR, "[Span %d D-Channel %d] PRI: %s", span, dchan, s);
+		else
+			ast_log(LOG_ERROR, "%s", s);
 	} else
 		ast_log(LOG_ERROR, "%s", s);
 




More information about the asterisk-commits mailing list