[PHP-DEV] PHP 4.0 Bug #3354: segfault when calling exit from a constructor From: rasmus <email protected>
Date: 01/29/00

From: rasmus <email protected>
Operating system: Linux
PHP version: 4.0 Latest CVS (29/01/2000)
PHP Bug Type: Scripting Engine problem
Bug description: segfault when calling exit from a constructor

Test script:
        class test {
                function test() {
                        exit;
                }
        }
        $a = new test();

Backtrace:
Program received signal SIGSEGV, Segmentation fault.
_mem_block_check (ptr=0x0, silent=1, __zend_filename=0x80d68a0 "zend_hash.c", __zend_lineno=588, __zend_orig_filename=0x0,
    __zend_orig_lineno=0) at zend_alloc.c:483
483 switch (p->magic) {
(gdb) bt
#0 _mem_block_check (ptr=0x0, silent=1, __zend_filename=0x80d68a0 "zend_hash.c", __zend_lineno=588, __zend_orig_filename=0x0,
    __zend_orig_lineno=0) at zend_alloc.c:483
#1 0x807c5b2 in _efree (ptr=0x0, __zend_filename=0x80d68a0 "zend_hash.c", __zend_lineno=588, __zend_orig_filename=0x0,
    __zend_orig_lineno=0) at zend_alloc.c:170
#2 0x808b3de in zend_hash_destroy (ht=0x81339c4) at zend_hash.c:588
#3 0x80589de in php_rshutdown_basic (type=1, module_number=17) at basic_functions.c:423
#4 0x808841a in module_registry_cleanup (module=0x8145e68) at zend_API.c:847
#5 0x808b6c5 in zend_hash_apply (ht=0x8135e80, destruct=0x80883ec <module_registry_cleanup>) at zend_hash.c:708
#6 0x8087cb4 in zend_deactivate () at zend.c:461
#7 0x8076035 in php_request_shutdown (dummy=0x0) at main.c:780
#8 0x80587f4 in main (argc=2, argv=0xbffffc54) at cgi_main.c:500

-- 
PHP Development Mailing List <http://www.php.net/>
To unsubscribe, e-mail: php-dev-unsubscribe <email protected>
For additional commands, e-mail: php-dev-help <email protected>
To contact the list administrators, e-mail: php-list-admin <email protected>