abies Fri Jun 4 12:54:14 2004 EDT
Modified files:
/php-src/ext/standard http.c
Log:
Fixed unregistered bug [crash in http_build_query()]
http://cvs.php.net/diff.php/php-src/ext/standard/http.c?r1=1.12&r2=1.13&ty=u
Index: php-src/ext/standard/http.c
diff -u php-src/ext/standard/http.c:1.12 php-src/ext/standard/http.c:1.13
--- php-src/ext/standard/http.c:1.12 Fri Feb 20 15:38:14 2004
+++ php-src/ext/standard/http.c Fri Jun 4 12:54:14 2004
@@ -16,7 +16,7 @@
+----------------------------------------------------------------------+
*/
-/* $Id: http.c,v 1.12 2004/02/20 20:38:14 pollita Exp $ */
+/* $Id: http.c,v 1.13 2004/06/04 16:54:14 abies Exp $ */
#include "php_http.h"
#include "php_ini.h"
@@ -55,7 +55,7 @@
(key_type = zend_hash_get_current_key_ex(ht, &key, &key_len, &idx, 0,
NULL)) != HASH_KEY_NON_EXISTANT;
zend_hash_move_forward(ht)
) {
- if (key_len && key[key_len-1] == '\0') {
+ if (key_type == HASH_KEY_IS_STRING && key_len && key[key_len-1] ==
'\0') {
/* We don't want that trailing NULL */
key_len -= 1;
}
--
PHP CVS Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php