From: Sterling Hughes Date: Sat, 14 Jun 2003 04:02:12 +0000 (+0000) Subject: This shouldn't be refcount = 0, causes a memory overrun X-Git-Tag: RELEASE_1_0_2~279 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=cc0c4e4981e636fafeaee85e0111781e58f6b2f5;p=php This shouldn't be refcount = 0, causes a memory overrun --- diff --git a/ext/simplexml/simplexml.c b/ext/simplexml/simplexml.c index 8f7fce0a67..4b31ae8bd0 100644 --- a/ext/simplexml/simplexml.c +++ b/ext/simplexml/simplexml.c @@ -97,11 +97,10 @@ static zval * sxe_property_read(zval *object, zval *member TSRMLS_DC) { zval *return_value; - zval *value; + zval *value = NULL; php_sxe_object *sxe; char *name; char *contents; - char *mapname = NULL; xmlNodePtr node; xmlAttrPtr attr; int counter = 0; @@ -122,7 +121,6 @@ sxe_property_read(zval *object, zval *member TSRMLS_DC) APPEND_PREV_ELEMENT(counter, value); MAKE_STD_ZVAL(value); - value->refcount = 0; contents = xmlNodeListGetString((xmlDocPtr) sxe->document->ptr, attr->children, 1); ZVAL_STRING(value, contents, 0); APPEND_CUR_ELEMENT(counter, value);