|
php.net | support | documentation | report a bug | advanced search | search howto | statistics | random bug | login |
PatchesPull RequestsHistoryAllCommentsChangesGit/SVN commits
[2013-12-16 16:59 UTC] bwoebi@php.net
-Status: Open
+Status: Duplicate
[2013-12-16 16:59 UTC] bwoebi@php.net
|
|||||||||||||||||||||||||||
Copyright © 2001-2025 The PHP GroupAll rights reserved. |
Last updated: Sun Nov 02 15:00:01 2025 UTC |
Description: ------------ php -n test.php Segmentation fault php -n -v PHP 5.5.7 (cli) (built: Dec 16 2013 15:06:06) Copyright (c) 1997-2013 The PHP Group Zend Engine v2.5.0, Copyright (c) 1998-2013 Zend Technologies php -n -m [PHP Modules] bcmath calendar Core ctype curl date dom ereg exif fileinfo filter gd hash iconv json libxml mbstring mcrypt mhash mysql mysqli mysqlnd openssl pcntl pcre PDO pdo_mysql posix Reflection session SimpleXML sockets SPL standard tidy tokenizer xml xmlrpc xmlwriter xsl zip zlib [Zend Modules] Test script: --------------- <?php class SegFault { public $aClassVariable = NULL; public function __construct( ) { list( $aVariable ) = $this->aClassVariable = array( NULL ); } } new SegFault( ); Actual result: -------------- php -n test.php Segmentation fault This runs on PHP 5.3 From PHP >5.3 crashes. <?php class NoSegFault { public $aClassVariable = NULL; public function __construct( ) { $this->aClassVariable = array( NULL ); list( $aVariable ) = $this->aClassVariable; } } new NoSegFault( );