[Asterisk-cvs] asterisk/channels chan_mgcp.c,1.66,1.67
markster at lists.digium.com
markster at lists.digium.com
Sun Aug 1 14:40:39 CDT 2004
Update of /usr/cvsroot/asterisk/channels
In directory localhost.localdomain:/tmp/cvs-serv25932/channels
Modified Files:
chan_mgcp.c
Log Message:
Make sure it's really a dotted IP (bug #2198)
Index: chan_mgcp.c
===================================================================
RCS file: /usr/cvsroot/asterisk/channels/chan_mgcp.c,v
retrieving revision 1.66
retrieving revision 1.67
diff -u -d -r1.66 -r1.67
--- chan_mgcp.c 1 Aug 2004 03:59:13 -0000 1.66
+++ chan_mgcp.c 1 Aug 2004 18:26:41 -0000 1.67
@@ -3417,7 +3417,7 @@
ast_mutex_init(&gw->msgs_lock);
strncpy(gw->name, cat, sizeof(gw->name) - 1);
/* SC: check if the name is numeric ip */
- if (inet_addr(gw->name) != INADDR_NONE)
+ if ((strchr(gw->name, '.')) && inet_addr(gw->name) != INADDR_NONE)
gw->isnamedottedip = 1;
}
while(v) {
More information about the svn-commits
mailing list