ID:               24592
 User updated by:  jhuston at cs dot umn dot edu
 Reported By:      jhuston at cs dot umn dot edu
 Status:           Open
 Bug Type:         Session related
 Operating System: Sparc Solaris 9
 PHP Version:      4.3.3RC2-dev
 New Comment:

I did the following configure line with fresh snapshot with debug
enabled.  Hopefully, this will pinpoint the problem even better.

./configure --disable-all --disable-cgi --enable-debug
--enable-session

Running php on test.php:

[EMAIL PROTECTED] php4-STABLE-200307151730]# sapi/cli/php -n test.php
It didn't crash at all yet.
[Tue Jul 15 12:45:46 2003]  Script:  'test.php'
---------------------------------------
/home/src/php4-STABLE-200307151730/ext/session/session.c(640) : Block
0x0018A5E8 status:
Beginning:      Overrun (magic=0x000000B4, expected=0x7312F8DC)
Segmentation fault

backtrace on gdb:

(gdb) run -n test.php
Starting program: /home/src/php4-STABLE-200307151730/sapi/cli/php -n
test.php
It didn't crash at all yet.
[Tue Jul 15 12:46:47 2003]  Script:  'test.php'
---------------------------------------
/home/src/php4-STABLE-200307151730/ext/session/session.c(640) : Block
0x0018A5E8 status:
Beginning:      Overrun (magic=0x000000B4, expected=0x7312F8DC)

Program received signal SIGSEGV, Segmentation fault.
0xff1f04f8 in memcpy () from
/usr/platform/SUNW,Sun-Blade-100/lib/libc_psr.so.1
(gdb) bt
#0  0xff1f04f8 in memcpy ()
   from /usr/platform/SUNW,Sun-Blade-100/lib/libc_psr.so.1
#1  0x10813c in _mem_block_check (ptr=0x18a610, silent=0, 
    __zend_filename=0x144410
"/home/src/php4-STABLE-200307151730/ext/session/session.c",
__zend_lineno=640, __zend_orig_filename=0x0, __zend_orig_lineno=0)
    at /home/src/php4-STABLE-200307151730/Zend/zend_alloc.c:675
#2  0x1080f4 in _mem_block_check (ptr=0x18a610, silent=1, 
    __zend_filename=0x144410
"/home/src/php4-STABLE-200307151730/ext/session/session.c",
__zend_lineno=640, __zend_orig_filename=0x0, __zend_orig_lineno=0)
    at /home/src/php4-STABLE-200307151730/Zend/zend_alloc.c:667
#3  0x106c88 in _efree (ptr=0x18a610, 
    __zend_filename=0x144410
"/home/src/php4-STABLE-200307151730/ext/session/session.c",
__zend_lineno=640, __zend_orig_filename=0x0, __zend_orig_lineno=0)
    at /home/src/php4-STABLE-200307151730/Zend/zend_alloc.c:243
#4  0x243f8 in migrate_global (ht=0x1bce50, pos=0xffbfefe4)
    at /home/src/php4-STABLE-200307151730/ext/session/session.c:640
#5  0x245bc in php_session_save_current_state ()
    at /home/src/php4-STABLE-200307151730/ext/session/session.c:670
#6  0x28494 in php_session_flush ()
    at /home/src/php4-STABLE-200307151730/ext/session/session.c:1593
#7  0x284e4 in zm_deactivate_session (type=1, module_number=2)
    at /home/src/php4-STABLE-200307151730/ext/session/session.c:1607
#8  0x12660c in module_registry_cleanup (module=0x1ad328)
    at /home/src/php4-STABLE-200307151730/Zend/zend_API.c:1167
#9  0x12a928 in zend_hash_apply (ht=0x18ba78, 
    apply_func=0x12659c <module_registry_cleanup>)
    at /home/src/php4-STABLE-200307151730/Zend/zend_hash.c:688
#10 0x1214b8 in zend_deactivate_modules ()
    at /home/src/php4-STABLE-200307151730/Zend/zend.c:651
#11 0xccaf4 in php_request_shutdown (dummy=0x0)
    at /home/src/php4-STABLE-200307151730/main/main.c:981
#12 0x142f48 in main (argc=3, argv=0xffbff5d4)
    at /home/src/php4-STABLE-200307151730/sapi/cli/php_cli.c:874


Previous Comments:
------------------------------------------------------------------------

[2003-07-15 10:56:14] jhuston at cs dot umn dot edu

I've also tried GCC 3.2 on Sun Solaris 5.8 and got the same results.

[EMAIL PROTECTED] (~/php4-STABLE-200307151530) % sapi/cli/php -n
../test.php
It didn't crash at all yet.
Bus error
[EMAIL PROTECTED] (~/php4-STABLE-200307151530) % gcc -v
Reading specs from
/soft/gcc-3.2/SunOS5.8/lib/gcc-lib/sparc-sun-solaris2.8/3.2/specs
Configured with: ./configure --prefix=/soft/gcc-3.2
--exec-prefix=/soft/gcc-3.2/SunOS5.8
Thread model: posix
gcc version 3.2
[EMAIL PROTECTED] (~/php4-STABLE-200307151530) % uname -a
SunOS thufir 5.8 Generic_108528-11 sun4u sparc

------------------------------------------------------------------------

[2003-07-15 10:21:27] jhuston at cs dot umn dot edu

[EMAIL PROTECTED] forum]% gcc -v
Reading specs from
/usr/local/lib/gcc-lib/sparc-sun-solaris2.8/2.95.3/specs
gcc version 2.95.3 20010315 (release)

and then I compiled it with Sun Workshop cc and got the same results as
if it was compiled with gcc.

[EMAIL PROTECTED] php4-STABLE-200307150330]# cc -V
cc: Sun WorkShop 6 update 1 C 5.2 2000/09/11

------------------------------------------------------------------------

[2003-07-15 02:18:39] [EMAIL PROTECTED]

Which compiler did you use? What version?


------------------------------------------------------------------------

[2003-07-14 23:18:51] jhuston at cs dot umn dot edu

Yes, it still crashes.

[EMAIL PROTECTED] php4-STABLE-200307150330]# sapi/cli/php -n
/home/projects/gradebook/test.php
It didn't crash at all yet.
Bus error
[EMAIL PROTECTED] php4-STABLE-200307150330]# gdb sapi/cli/php
GNU gdb 5.0
Copyright 2000 Free Software Foundation, Inc.
GDB is free software, covered by the GNU General Public License, and
you are
welcome to change it and/or distribute copies of it under certain
conditions.
Type "show copying" to see the conditions.
There is absolutely no warranty for GDB.  Type "show warranty" for
details.
This GDB was configured as "sparc-sun-solaris2.8"...
(gdb) run -n /home/projects/gradebook/test.php
Starting program: /home/src/php4-STABLE-200307150330/sapi/cli/php -n
/home/projects/gradebook/test.php
It didn't crash at all yet.

Program received signal SIGSEGV, Segmentation fault.
0x9f394 in _efree (ptr=0x10a6d8)
    at /home/src/php4-STABLE-200307150330/Zend/zend_alloc.c:259
259             REMOVE_POINTER_FROM_LIST(p);
(gdb) where
#0  0x9f394 in _efree (ptr=0x10a6d8)
    at /home/src/php4-STABLE-200307150330/Zend/zend_alloc.c:259
#1  0x237b4 in migrate_global (ht=0x13a558, pos=0x1)
    at /home/src/php4-STABLE-200307150330/ext/session/session.c:640
#2  0x238b8 in php_session_save_current_state ()
    at /home/src/php4-STABLE-200307150330/ext/session/session.c:670
#3  0x26058 in php_session_flush ()
    at /home/src/php4-STABLE-200307150330/ext/session/session.c:1593
#4  0x26088 in zm_deactivate_session (type=0, module_number=2)
    at /home/src/php4-STABLE-200307150330/ext/session/session.c:1607
#5  0xb14b8 in module_registry_cleanup (module=0x12d1e8)
    at /home/src/php4-STABLE-200307150330/Zend/zend_API.c:1167
#6  0xb3498 in zend_hash_apply (ht=0x10bb2c, 
    apply_func=0xb147c <module_registry_cleanup>)
    at /home/src/php4-STABLE-200307150330/Zend/zend_hash.c:688
#7  0xae530 in zend_deactivate_modules ()
    at /home/src/php4-STABLE-200307150330/Zend/zend.c:651
#8  0x83060 in php_request_shutdown (dummy=0x0)
    at /home/src/php4-STABLE-200307150330/main/main.c:981
#9  0xc883c in main (argc=3, argv=0xffbff5c4)
    at /home/src/php4-STABLE-200307150330/sapi/cli/php_cli.c:874

------------------------------------------------------------------------

[2003-07-14 21:05:32] [EMAIL PROTECTED]

Can you please try this configure line with fresh snapshot:

# ./configure --disable-all --disable-cgi --enable-session

And run the test script like this:

# sapi/cli/php -n test.php

Does it still crash..?
 

------------------------------------------------------------------------

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/24592

-- 
Edit this bug report at http://bugs.php.net/?id=24592&edit=1

Reply via email to