cvs: php-src(PHP_5_2) /ext/standard var.c

From: Date: Mon, 24 Jul 2006 23:40:57 +0000
Subject: cvs: php-src(PHP_5_2) /ext/standard var.c
Groups: php.cvs 
Request: Send a blank email to php-cvs+get-39500@lists.php.net to get a copy of this message
helly Mon Jul 24 23:40:57 2006 UTC Modified files: (Branch: PHP_5_2) /php-src/ext/standard var.c Log: - MFH Correctly handle binary proeprty names which are not mangled http://cvs.php.net/viewvc.cgi/php-src/ext/standard/var.c?r1=1.203.2.7.2.4&r2=1.203.2.7.2.5&diff_format=u Index: php-src/ext/standard/var.c diff -u php-src/ext/standard/var.c:1.203.2.7.2.4 php-src/ext/standard/var.c:1.203.2.7.2.5 --- php-src/ext/standard/var.c:1.203.2.7.2.4 Mon Jul 24 18:03:45 2006 +++ php-src/ext/standard/var.c Mon Jul 24 23:40:57 2006 @@ -18,7 +18,7 @@ +----------------------------------------------------------------------+ */ -/* $Id: var.c,v 1.203.2.7.2.4 2006/07/24 18:03:45 helly Exp $ */ +/* $Id: var.c,v 1.203.2.7.2.5 2006/07/24 23:40:57 helly Exp $ */ @@ -76,8 +76,8 @@ if (hash_key->nKeyLength ==0 ) { /* numeric key */ php_printf("%*c[%ld]=>\n", level + 1, ' ', hash_key->h); } else { /* string key */ - zend_unmangle_property_name(hash_key->arKey, hash_key->nKeyLength-1, &class_name, &prop_name); - if (class_name) { + int unmangle = zend_unmangle_property_name(hash_key->arKey, hash_key->nKeyLength-1, &class_name, &prop_name); + if (class_name && unmangle == SUCCESS) { php_printf("%*c[\"%s", level + 1, ' ', prop_name); if (class_name[0]=='*') { ZEND_PUTS(":protected"); @@ -85,7 +85,8 @@ ZEND_PUTS(":private"); } } else { - php_printf("%*c[\"%s", level + 1, ' ', hash_key->arKey); + php_printf("%*c[\"", level + 1, ' '); + PHPWRITE(hash_key->arKey, hash_key->nKeyLength - 1); #ifdef ANDREY_0 ZEND_PUTS(":public"); #endif

« previous php.cvs (#39500) next »