diff options
author | Marcus Boerger <helly@php.net> | 2006-05-25 10:01:30 +0000 |
---|---|---|
committer | Marcus Boerger <helly@php.net> | 2006-05-25 10:01:30 +0000 |
commit | a91df0f95fe6417b0f41b34b24818417f91e5a0c (patch) | |
tree | 8ca54443c22b0d7989de8151313b5a5c964408d8 | |
parent | 1b237976ad2a69b6d91429ffd9fee54f7d0b9bca (diff) | |
download | php-git-a91df0f95fe6417b0f41b34b24818417f91e5a0c.tar.gz |
- MFH Fixed bug #37587 (var without attribute causes segfault
-rw-r--r-- | NEWS | 3 | ||||
-rw-r--r-- | ext/wddx/wddx.c | 10 |
2 files changed, 7 insertions, 6 deletions
@@ -1,6 +1,7 @@ PHP NEWS ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||| -?? ??? 2006, PHP 5.?.? +?? ??? 2006, PHP 5.1.5 +- Fixed bug #37587 (var without attribute causes segfault). (Marcus) - Fixed bug #37576 (FastCGI env (cgi vars) table overflow). (Piotr) - Fixed bug #37496 (FastCGI output buffer overrun). (Piotr, Dmitry) - Fixed bug #37487 (oci_fetch_array() array-type should always default to diff --git a/ext/wddx/wddx.c b/ext/wddx/wddx.c index b2833b2f11..e83ba8ccda 100644 --- a/ext/wddx/wddx.c +++ b/ext/wddx/wddx.c @@ -751,7 +751,7 @@ static void php_wddx_push_element(void *user_data, const XML_Char *name, const X } else if (!strcmp(name, EL_CHAR)) { int i; - for (i = 0; atts[i]; i++) { + if (atts) for (i = 0; atts[i]; i++) { if (!strcmp(atts[i], EL_CHAR_CODE) && atts[++i] && atts[i][0]) { char tmp_buf[2]; @@ -771,7 +771,7 @@ static void php_wddx_push_element(void *user_data, const XML_Char *name, const X } else if (!strcmp(name, EL_BOOLEAN)) { int i; - for (i = 0; atts[i]; i++) { + if (atts) for (i = 0; atts[i]; i++) { if (!strcmp(atts[i], EL_VALUE) && atts[++i] && atts[i][0]) { ent.type = ST_BOOLEAN; SET_STACK_VARNAME; @@ -812,7 +812,7 @@ static void php_wddx_push_element(void *user_data, const XML_Char *name, const X } else if (!strcmp(name, EL_VAR)) { int i; - for (i = 0; atts[i]; i++) { + if (atts) for (i = 0; atts[i]; i++) { if (!strcmp(atts[i], EL_NAME) && atts[++i] && atts[i][0]) { char *decoded; int decoded_len; @@ -829,7 +829,7 @@ static void php_wddx_push_element(void *user_data, const XML_Char *name, const X MAKE_STD_ZVAL(ent.data); array_init(ent.data); - for (i = 0; atts[i]; i++) { + if (atts) for (i = 0; atts[i]; i++) { if (!strcmp(atts[i], "fieldNames") && atts[++i] && atts[i][0]) { zval *tmp; char *key; @@ -869,7 +869,7 @@ static void php_wddx_push_element(void *user_data, const XML_Char *name, const X ent.varname = NULL; ent.data = NULL; - for (i = 0; atts[i]; i++) { + if (atts) for (i = 0; atts[i]; i++) { if (!strcmp(atts[i], EL_NAME) && atts[++i] && atts[i][0]) { char *decoded; int decoded_len; |