cvs: php4 /ext/ircg ircg.c
| From: | Sascha Schumann | Date: | Sat, 28 Apr 2001 15:43:14 +0000 |
| Subject: | cvs: php4 /ext/ircg ircg.c | ||
| Groups: | php.cvs | ||
| Request: | Send a blank email to php-cvs+get-5347@lists.php.net to get a copy of this message | ||
sas Sat Apr 28 08:43:14 2001 EDT
Modified files:
/php4/ext/ircg ircg.c
Log:
ircg_mirc_color() does not use emalloc anymore to allocate strings,
so ircg_html_encode() needs to copy the return value.
Index: php4/ext/ircg/ircg.c
diff -u php4/ext/ircg/ircg.c:1.67 php4/ext/ircg/ircg.c:1.68
--- php4/ext/ircg/ircg.c:1.67 Sat Apr 28 07:06:41 2001
+++ php4/ext/ircg/ircg.c Sat Apr 28 08:43:14 2001
@@ -16,7 +16,7 @@
+----------------------------------------------------------------------+
*/
-/* $Id: ircg.c,v 1.67 2001/04/28 14:06:41 sas Exp $ */
+/* $Id: ircg.c,v 1.68 2001/04/28 15:43:14 sas Exp $ */
#include <time.h>
@@ -1022,7 +1022,9 @@
ircg_mirc_color(Z_STRVAL_PP(p1), &res, Z_STRLEN_PP(p1));
- RETVAL_STRINGL(res.c, res.len, 0);
+ RETVAL_STRINGL(res.c, res.len, 1);
+
+ smart_str_free_ex(&res, 1);
}
PHP_FUNCTION(ircg_kick)