[Asterisk-cvs] asterisk/channels chan_iax2.c,1.373,1.374
kpfleming
kpfleming
Thu Nov 10 18:43:44 CST 2005
Update of /usr/cvsroot/asterisk/channels
In directory mongoose.digium.com:/tmp/cvs-serv10159/channels
Modified Files:
chan_iax2.c
Log Message:
issue #5685
Index: chan_iax2.c
===================================================================
RCS file: /usr/cvsroot/asterisk/channels/chan_iax2.c,v
retrieving revision 1.373
retrieving revision 1.374
diff -u -d -r1.373 -r1.374
--- chan_iax2.c 9 Nov 2005 19:05:52 -0000 1.373
+++ chan_iax2.c 10 Nov 2005 23:34:30 -0000 1.374
@@ -1970,6 +1970,7 @@
{
int which = 0;
struct iax2_peer *p;
+ char *res = NULL;
/* 0 - iax2; 1 - show; 2 - peer; 3 - <peername> */
if(pos == 3) {
@@ -1977,14 +1978,15 @@
for(p = peerl.peers ; p ; p = p->next) {
if(!strncasecmp(p->name, word, strlen(word))) {
if(++which > state) {
- return strdup(p->name);
+ res = strdup(p->name);
+ break;
}
}
}
ast_mutex_unlock(&peerl.lock);
}
- return NULL;
+ return res;
}
static int iax2_show_stats(int fd, int argc, char *argv[])
More information about the svn-commits
mailing list