[Freeswitch-svn] [commit] r13338 - in freeswitch/trunk/libs/sofia-sip: . utils

FreeSWITCH SVN mikej at freeswitch.org
Fri May 15 09:06:43 PDT 2009


Author: mikej
Date: Fri May 15 11:06:43 2009
New Revision: 13338

Log:
Wed May 13 11:07:04 CDT 2009  Pekka Pessi <first.last at nokia.com>
  * sip-dig.c: fixed buffer overrun
  Ignore-this: d8776bd28ef951602449e87d80dc20e7
  
  Coverity issue.


Modified:
   freeswitch/trunk/libs/sofia-sip/.update
   freeswitch/trunk/libs/sofia-sip/utils/sip-dig.c

Modified: freeswitch/trunk/libs/sofia-sip/.update
==============================================================================
--- freeswitch/trunk/libs/sofia-sip/.update	(original)
+++ freeswitch/trunk/libs/sofia-sip/.update	Fri May 15 11:06:43 2009
@@ -1 +1 @@
-Fri May 15 11:05:48 CDT 2009
+Fri May 15 11:06:28 CDT 2009

Modified: freeswitch/trunk/libs/sofia-sip/utils/sip-dig.c
==============================================================================
--- freeswitch/trunk/libs/sofia-sip/utils/sip-dig.c	(original)
+++ freeswitch/trunk/libs/sofia-sip/utils/sip-dig.c	Fri May 15 11:06:43 2009
@@ -52,7 +52,6 @@
  * The @e sip-dig utility accepts following command line options:
  * <dl>
  * <dt>-p <em>protoname</em></dt>
-
  * <dd>Use named transport protocol. The <em>protoname</em> can be either
  * well-known, e.g., "udp", or it can specify NAPTR service and SRV
  * identifier, e.g., "tls-udp/SIPS+D2U/_sips._udp.".
@@ -160,7 +159,7 @@
 
   unsigned preference, ip4, ip6, sips, print;
 
-  struct transport tports[N_TPORT];
+  struct transport tports[N_TPORT + 1];
 };
 
 int dig_naptr(struct dig *dig, char const *host, double weight);
@@ -370,7 +369,7 @@
   struct transport *tports = dig->tports;
   int j;
 
-  for (j = 0; j < N_TPORT - 1; j++) {
+  for (j = 0; j < N_TPORT; j++) {
     if (!tports[j].name)
       break;
     if (su_casematch(tports[j].name, tport))



More information about the Freeswitch-svn mailing list