[Freeswitch-svn] [commit] r5070 - freeswitch/trunk/libs/iksemel/src

Freeswitch SVN anthm at freeswitch.org
Wed May 2 13:38:25 EDT 2007


Author: anthm
Date: Wed May  2 13:38:25 2007
New Revision: 5070

Modified:
   freeswitch/trunk/libs/iksemel/src/io-posix.c

Log:
sigh

Modified: freeswitch/trunk/libs/iksemel/src/io-posix.c
==============================================================================
--- freeswitch/trunk/libs/iksemel/src/io-posix.c	(original)
+++ freeswitch/trunk/libs/iksemel/src/io-posix.c	Wed May  2 13:38:25 2007
@@ -110,12 +110,11 @@
 	tv.tv_sec = timeout;
 	if (timeout != -1) tvptr = &tv; else tvptr = NULL;
 	if (select (sock + 1, &fds, NULL, NULL, tvptr) > 0) {
-		memset(buffer, 0, buf_len);
 		len = recv (sock, buffer, buf_len, 0);
 		if (len > 0) {
 			char *p, *e = NULL, *t = NULL;
+			*(buffer+buf_len+1) = '\0';
 			for (p = buffer; p && *p; p++) {
-
 				if (*p == '>') {
 					e = p;
 					t = p+1;



More information about the Freeswitch-svn mailing list