[asterisk-commits] mmichelson: trunk r133106 - in /trunk: ./ apps/app_chanspy.c

SVN commits to the Asterisk project asterisk-commits at lists.digium.com
Wed Jul 23 14:07:56 CDT 2008


Author: mmichelson
Date: Wed Jul 23 14:07:56 2008
New Revision: 133106

URL: http://svn.digium.com/view/asterisk?view=rev&rev=133106
Log:
Merged revisions 133104 via svnmerge from 
https://origsvn.digium.com/svn/asterisk/branches/1.4

........
r133104 | mmichelson | 2008-07-23 14:06:16 -0500 (Wed, 23 Jul 2008) | 5 lines

Zap/pseudo is ten characters, but DAHDI/pseudo is
twelve. The strncmp call in next_channel should
account for this.


........

Modified:
    trunk/   (props changed)
    trunk/apps/app_chanspy.c

Propchange: trunk/
------------------------------------------------------------------------------
Binary property 'branch-1.4-merged' - no diff available.

Modified: trunk/apps/app_chanspy.c
URL: http://svn.digium.com/view/asterisk/trunk/apps/app_chanspy.c?view=diff&rev=133106&r1=133105&r2=133106
==============================================================================
--- trunk/apps/app_chanspy.c (original)
+++ trunk/apps/app_chanspy.c Wed Jul 23 14:07:56 2008
@@ -51,6 +51,9 @@
 
 #define AST_NAME_STRLEN 256
 #define NUM_SPYGROUPS 128
+
+ /* "DAHDI/pseudo" is twelve characters */
+#define PSEUDO_CHAN_LEN 12
 
 static const char *tdesc = "Listen to a channel, and optionally whisper into it";
 static const char *app_chan = "ChanSpy";
@@ -609,7 +612,7 @@
 		return NULL;
 
 	snprintf(channel_name, AST_CHANNEL_NAME, "%s/pseudo", dahdi_chan_name);
-	if (!strncmp(next->name, channel_name, 10)) {
+	if (!strncmp(next->name, channel_name, PSEUDO_CHAN_LEN)) {
 		last = next;
 		ast_channel_unlock(next);
 		goto redo;




More information about the asterisk-commits mailing list