[asterisk-commits] mmichelson: trunk r218504 - /trunk/channels/chan_sip.c

SVN commits to the Asterisk project asterisk-commits at lists.digium.com
Tue Sep 15 10:05:56 CDT 2009


Author: mmichelson
Date: Tue Sep 15 10:05:53 2009
New Revision: 218504

URL: http://svn.asterisk.org/svn-view/asterisk?view=rev&rev=218504
Log:
Ensure that SDP read from TCP socket is null-terminated.


Modified:
    trunk/channels/chan_sip.c

Modified: trunk/channels/chan_sip.c
URL: http://svn.asterisk.org/svn-view/asterisk/trunk/channels/chan_sip.c?view=diff&rev=218504&r1=218503&r2=218504
==============================================================================
--- trunk/channels/chan_sip.c (original)
+++ trunk/channels/chan_sip.c Tue Sep 15 10:05:53 2009
@@ -2967,6 +2967,7 @@
 					ast_mutex_unlock(&tcptls_session->lock);
 					goto cleanup;
 				}
+				buf[sizeof(buf)-1] = '\0';
 				ast_mutex_unlock(&tcptls_session->lock);
 				if (me->stop)
 					goto cleanup;




More information about the asterisk-commits mailing list