From: gasol dot wu at gmail dot com Operating system: MacOS X 10.8/FreeBSD 9.1 PHP version: 5.4.11 Package: Scripting Engine problem Bug Type: Bug Bug description:It's possible to change constant value in C extension.
Description: ------------ I have encounter this problem couple weeks ago, So I write some tests to see different result between PHP 5.3 and PHP 5.4 (even in 5.4.11). https://github.com/Gasol/const_test Testing Result: 5.4.11 ===================================================================== PHP : /Users/gasol/.phpbrew/php/php-5.4.11/bin/php PHP_SAPI : cli PHP_VERSION : 5.4.11 ZEND_VERSION: 2.4.0 PHP_OS : Darwin - Darwin gasol-mbp 12.2.0 Darwin Kernel Version 12.2.0: Sat Aug 25 00:48:52 PDT 2012; root:xnu-2050.18.24~1/RELEASE_X86_64 x86_64 INI actual : /Users/gasol/Code/const_test/tmp-php.ini More .INIs : CWD : /Users/gasol/Code/const_test Extra dirs : VALGRIND : Not used ===================================================================== TIME START 2013-01-23 05:52:33 ===================================================================== PASS Check for const_test presence [tests/001-load.phpt] FAIL Check for modify custom constant [tests/002-modify_const.phpt] PASS Check for modify constant declared in class [tests/003- modify_class_const.phpt] FAIL Check for modify system constant [tests/004-modify_system_const.phpt] ===================================================================== TIME END 2013-01-23 05:52:33 PHP 5.3.21 ===================================================================== PHP : /Users/gasol/.phpbrew/php/php-5.3.21/bin/php PHP_SAPI : cli PHP_VERSION : 5.3.21 ZEND_VERSION: 2.3.0 PHP_OS : Darwin - Darwin gasol-mbp 12.2.0 Darwin Kernel Version 12.2.0: Sat Aug 25 00:48:52 PDT 2012; root:xnu-2050.18.24~1/RELEASE_X86_64 x86_64 INI actual : /Users/gasol/Code/const_test/tmp-php.ini More .INIs : CWD : /Users/gasol/Code/const_test Extra dirs : VALGRIND : Not used ===================================================================== TIME START 2013-01-23 06:03:06 ===================================================================== PASS Check for const_test presence [tests/001-load.phpt] PASS Check for modify custom constant [tests/002-modify_const.phpt] PASS Check for modify constant declared in class [tests/003- modify_class_const.phpt] PASS Check for modify system constant [tests/004-modify_system_const.phpt] ===================================================================== TIME END 2013-01-23 06:03:06 -- Edit bug report at https://bugs.php.net/bug.php?id=64053&edit=1 -- Try a snapshot (PHP 5.4): https://bugs.php.net/fix.php?id=64053&r=trysnapshot54 Try a snapshot (PHP 5.3): https://bugs.php.net/fix.php?id=64053&r=trysnapshot53 Try a snapshot (trunk): https://bugs.php.net/fix.php?id=64053&r=trysnapshottrunk Fixed in SVN: https://bugs.php.net/fix.php?id=64053&r=fixed Fixed in release: https://bugs.php.net/fix.php?id=64053&r=alreadyfixed Need backtrace: https://bugs.php.net/fix.php?id=64053&r=needtrace Need Reproduce Script: https://bugs.php.net/fix.php?id=64053&r=needscript Try newer version: https://bugs.php.net/fix.php?id=64053&r=oldversion Not developer issue: https://bugs.php.net/fix.php?id=64053&r=support Expected behavior: https://bugs.php.net/fix.php?id=64053&r=notwrong Not enough info: https://bugs.php.net/fix.php?id=64053&r=notenoughinfo Submitted twice: https://bugs.php.net/fix.php?id=64053&r=submittedtwice register_globals: https://bugs.php.net/fix.php?id=64053&r=globals PHP 4 support discontinued: https://bugs.php.net/fix.php?id=64053&r=php4 Daylight Savings: https://bugs.php.net/fix.php?id=64053&r=dst IIS Stability: https://bugs.php.net/fix.php?id=64053&r=isapi Install GNU Sed: https://bugs.php.net/fix.php?id=64053&r=gnused Floating point limitations: https://bugs.php.net/fix.php?id=64053&r=float No Zend Extensions: https://bugs.php.net/fix.php?id=64053&r=nozend MySQL Configuration Error: https://bugs.php.net/fix.php?id=64053&r=mysqlcfg
