Bug #48930 [Csd]: __COMPILER_HALT_OFFSET__ incorrect in PHP>=5.3
| From: | adam-phpbugs at adam dot gs | Date: | Tue, 29 Jun 2010 16:44:18 +0000 |
| Subject: | Bug #48930 [Csd]: __COMPILER_HALT_OFFSET__ incorrect in PHP>=5.3 | ||
| References: | 1 | Groups: | php.bugs |
| Request: | Send a blank email to php-bugs+get-151962@lists.php.net to get a copy of this message | ||
Edit report at http://bugs.php.net/bug.php?id=48930&edit=1
ID: 48930
User updated by: adam-phpbugs at adam dot gs
Reported by: adam-phpbugs at adam dot gs
Summary: __COMPILER_HALT_OFFSET__ incorrect in PHP>=5.3
Status: Closed
Type: Bug
Package: Scripting Engine problem
Operating System: *
PHP Version: 5.3, 6
Assigned To: felipe
New Comment:
Thats awesome....
Previous Comments:
------------------------------------------------------------------------
[2010-06-29 13:54:04] felipe@php.net
The fix has been reverted for 5.3 branch because it breaks binary
compatibility.
------------------------------------------------------------------------
[2010-06-29 13:37:15] felipe@php.net
Automatic comment from SVN on behalf of felipe
Revision: http://svn.php.net/viewvc/?view=revision&revision=300854
Log: - Reverted fix for bug #48930 (due binary compatibility breakage)
------------------------------------------------------------------------
[2010-06-28 00:41:28] adam-phpbugs at adam dot gs
I lied, It just hasn't hit the snapshots yet, works from SVN sources!
-=[~/Scripts/compile/php-src-5.3]=- -=[Sun Jun 27]=- -=[18:40:12]=-
[adam@nighe]$ ./sapi/cli/php test-with-shebang.php
string(19) "
this is test data
"
-=[~/Scripts/compile/php-src-5.3]=- -=[Sun Jun 27]=- -=[18:40:17]=-
[adam@nighe]$ ./sapi/cli/php test-without-shebang.php
string(19) "
this is test data
"
Thanks very much felipe!
------------------------------------------------------------------------
[2010-06-28 00:16:40] adam-phpbugs at adam dot gs
Hi felipe,
Thanks for taking a look at this bug, its languished for (what i'd
consider) far
too long.
Unfortunately it doesn't seem to fix the issue:
-=[~/Scripts/compile/php5.3-201006272030]=- -=[Sun Jun 27]=-
-=[18:14:16]=-
[adam@nighe]$ ./sapi/cli/php -v
PHP 5.3.3RC2-dev (cli) (built: Jun 27 2010 17:54:04)
Copyright (c) 1997-2010 The PHP Group
Zend Engine v2.3.0, Copyright (c) 1998-2010 Zend Technologies
-=[~/Scripts/compile/php5.3-201006272030]=- -=[Sun Jun 27]=-
-=[18:15:11]=-
[adam@nighe]$ php -v
PHP 5.3.1 (cli) (built: Dec 26 2009 19:21:45)
Copyright (c) 1997-2009 The PHP Group
Zend Engine v2.3.0, Copyright (c) 1998-2009 Zend Technologies
-=[~/Scripts/compile/php5.3-201006272030]=- -=[Sun Jun 27]=-
-=[18:15:15]=-
[adam@nighe]$ ./sapi/cli/php test-without-shebang.php
string(19) "
this is test data
"
-=[~/Scripts/compile/php5.3-201006272030]=- -=[Sun Jun 27]=-
-=[18:15:30]=-
[adam@nighe]$ ./sapi/cli/php test-with-shebang.php
string(40) ");
__halt_compiler();
this is test data
"
-=[~/Scripts/compile/php5.3-201006272030]=- -=[Sun Jun 27]=-
-=[18:15:34]=-
[adam@nighe]$ php test-with-shebang.php
string(40) ");
__halt_compiler();
this is test data
"
-=[~/Scripts/compile/php5.3-201006272030]=- -=[Sun Jun 27]=-
-=[18:15:38]=-
[adam@nighe]$ php test-without-shebang.php
string(19) "
this is test data
"
-=[~/Scripts/compile/php5.3-201006272030]=- -=[Sun Jun 27]=-
-=[18:15:44]=-
[adam@nighe]$ cat test-without-shebang.php
<?php
$fh=fopen(__FILE__,"r");
fseek($fh,__COMPILER_HALT_OFFSET__);
var_dump(fread($fh,1024));
fclose($fh);
__halt_compiler();
this is test data
-=[~/Scripts/compile/php5.3-201006272030]=- -=[Sun Jun 27]=-
-=[18:15:54]=-
[adam@nighe]$ cat test-with-shebang.php
#!/usr/local/bin/php
<?php
$fh=fopen(__FILE__,"r");
fseek($fh,__COMPILER_HALT_OFFSET__);
var_dump(fread($fh,1024));
fclose($fh);
__halt_compiler();
this is test data
------------------------------------------------------------------------
[2010-06-27 23:46:18] felipe@php.net
Automatic comment from SVN on behalf of felipe
Revision: http://svn.php.net/viewvc/?view=revision&revision=300789
Log: - Fixed bug #48930 (__COMPILER_HALT_OFFSET__ incorrect in PHP >=
5.3)
------------------------------------------------------------------------
The remainder of the comments for this report are too long. To view
the rest of the comments, please view the bug report online at
http://bugs.php.net/bug.php?id=48930
--
Edit this bug report at http://bugs.php.net/bug.php?id=48930&edit=1