#32457 [NEW]: xml_parse_into_struct stops short without error if xml attributes are unquoted

From: Date: Fri, 25 Mar 2005 18:05:46 +0000
Subject: #32457 [NEW]: xml_parse_into_struct stops short without error if xml attributes are unquoted
Groups: php.bugs 
Request: Send a blank email to php-bugs+get-75866@lists.php.net to get a copy of this message
From: cephalicmarble at blueyonder dot co dot uk Operating system: Linux PHP version: 5.0.3 PHP Bug Type: XML related Bug description: xml_parse_into_struct stops short without error if xml attributes are unquoted Description: ------------ xml_parse_into_struct returns nodes correctly until it encounters an unquoted attribute. The function bombs without error. Reproduce code: --------------- <?php $sample = "<?xml version=\"1.0\"?><doc><test attr=unquoted/><next/><again/></doc>"; $parser = xml_parser_create(); $res = xml_parse_into_struct($parser,$sample,$vals,$index); xml_parser_free($parser); //var_dump($vals); echo sizeof($vals); ?> Expected result: ---------------- sizeof($vals) is one. Quote the attribute and it should be 5. -- Edit bug report at http://bugs.php.net/?id=32457&edit=1 -- Try a CVS snapshot (php4): http://bugs.php.net/fix.php?id=32457&r=trysnapshot4 Try a CVS snapshot (php5.0): http://bugs.php.net/fix.php?id=32457&r=trysnapshot50 Try a CVS snapshot (php5.1): http://bugs.php.net/fix.php?id=32457&r=trysnapshot51 Fixed in CVS: http://bugs.php.net/fix.php?id=32457&r=fixedcvs Fixed in release: http://bugs.php.net/fix.php?id=32457&r=alreadyfixed Need backtrace: http://bugs.php.net/fix.php?id=32457&r=needtrace Need Reproduce Script: http://bugs.php.net/fix.php?id=32457&r=needscript Try newer version: http://bugs.php.net/fix.php?id=32457&r=oldversion Not developer issue: http://bugs.php.net/fix.php?id=32457&r=support Expected behavior: http://bugs.php.net/fix.php?id=32457&r=notwrong Not enough info: http://bugs.php.net/fix.php?id=32457&r=notenoughinfo Submitted twice: http://bugs.php.net/fix.php?id=32457&r=submittedtwice register_globals: http://bugs.php.net/fix.php?id=32457&r=globals PHP 3 support discontinued: http://bugs.php.net/fix.php?id=32457&r=php3 Daylight Savings: http://bugs.php.net/fix.php?id=32457&r=dst IIS Stability: http://bugs.php.net/fix.php?id=32457&r=isapi Install GNU Sed: http://bugs.php.net/fix.php?id=32457&r=gnused Floating point limitations: http://bugs.php.net/fix.php?id=32457&r=float No Zend Extensions: http://bugs.php.net/fix.php?id=32457&r=nozend MySQL Configuration Error: http://bugs.php.net/fix.php?id=32457&r=mysqlcfg

« previous php.bugs (#75866) next »