jay Wed Nov 12 17:01:03 2003 EDT
Modified files:
/php-src/ext/standard fsock.c
Log:
Plugged a small memleak when errstr isn't efree()'d.
Index: php-src/ext/standard/fsock.c
diff -u php-src/ext/standard/fsock.c:1.116 php-src/ext/standard/fsock.c:1.117
--- php-src/ext/standard/fsock.c:1.116 Thu Aug 28 12:49:57 2003
+++ php-src/ext/standard/fsock.c Wed Nov 12 17:01:02 2003
@@ -18,7 +18,7 @@
+----------------------------------------------------------------------+
*/
-/* $Id: fsock.c,v 1.116 2003/08/28 16:49:57 sas Exp $ */
+/* $Id: fsock.c,v 1.117 2003/11/12 22:01:02 jay Exp $ */
#include "php.h"
#include "php_globals.h"
@@ -100,6 +100,10 @@
zval_dtor(zerrstr);
ZVAL_STRING(zerrstr, errstr, 0);
}
+ else if (!zerrstr && errstr) {
+ efree(errstr);
+ }
+
RETURN_FALSE;
}
--
PHP CVS Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php