php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #50723 Bug in garbage collector causes crash
Submitted: 2010-01-11 23:06 UTC Modified: 2010-02-02 12:33 UTC
From: garretts at microsoft dot com Assigned: dmitry (profile)
Status: Closed Package: Reproducible crash
PHP Version: 5.3.2RC1 OS: Windows
Private report: No CVE-ID: None
 [2010-01-11 23:06 UTC] garretts at microsoft dot com
Description:
------------
I've got a script which I've pared down from a much larger one, that causes a crash when php exits.

This happens in 5.3.3 as well.

The repro script is 340 lines. Removing any code (even a print statement) makes the problem go away.


Reproduce code:
---------------
Repro script:

http://fearthecowboy.com/downloads/test-crash.php.txt

Expected result:
----------------
It shouldn't crash. 

Actual result:
--------------
trace:
Function     Arg 1     Arg 2     Arg 3   Source 
php5!gc_collect_cycles+505     008aff78     01d2f6c4     52f33031    
php5!gc_collect_cycles+3ba     00000000     01d2f6e4     52fd49dc    
php5!gc_collect_cycles+54     00000078     0000000d     01d2f720    
php5!zend_deactivate+b2     00000001     00000088     0083be10    
php5!php_request_shutdown+259     00000000     02eb0100     00980150    
php!main+1526     00000002     00984a10     009828d8    
php!_setjmp3+160     7efde000     01d2fce4     771f9d72    
kernel32!BaseThreadInitThunk+e     7efde000     d0f01e21     00000000    
ntdll!__RtlUserThreadStart+70     00c934ea     7efde000     ffffffff    
ntdll!_RtlUserThreadStart+1b     00c934ea     7efde000     00000000    


Patches

Pull Requests

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2010-01-11 23:29 UTC] johannes@php.net
Please try using this snapshot:

  http://snaps.php.net/php5.3-latest.tar.gz
 
For Windows:

  http://windows.php.net/snapshots/

I couldn't reproduce this on different configurations (not on windows though) and recently there were some fixes for gc. Could you please try the latest snapshot to make sure you're still seeing this after the changes went in?
 [2010-01-12 19:11 UTC] garretts at microsoft dot com
Unfortunately, snapshots aren't working, but I updated from SVN this morning and compiled again, and the bug is still there. 

It's only happening on Windows, not Linux:

Platform 
--------------------------------------
Linux	5.3.1 (from source)	no
Linux	5.3.2-rc1 (from source)	no

Win	5.2.12.1 (nts vc6)	no
Win	5.3.1 (nts vc9)       	no

Win	5.3.2-rc1 (nts vc9)	yes
Win	5.3.3-svn (nts vc9)	yes

I'm not familiar with the garbage collector; I poked around, but I didn't get anywhere.
 [2010-01-19 01:00 UTC] php-bugs at lists dot php dot net
No feedback was provided for this bug for over a week, so it is
being suspended automatically. If you are able to provide the
information that was originally requested, please do so and change
the status of the bug back to "Open".
 [2010-02-01 22:20 UTC] garretts at microsoft dot com
I've tested again with:

   PHP 5.3.3-dev (cli) (built: Feb  1 2010 12:22:19)

And it is still crashing on the script.

G
 [2010-02-01 23:12 UTC] pajoye@php.net
Same here but with a different bt:

http://pastie.org/805036

Dmitry, can you try to look at it? Windows only tho'
 [2010-02-02 12:32 UTC] svn@php.net
Automatic comment from SVN on behalf of dmitry
Revision: http://svn.php.net/viewvc/?view=revision&revision=294334
Log: Fixed bug #50723 (Bug in garbage collector causes crash)
 [2010-02-02 12:33 UTC] dmitry@php.net
This bug has been fixed in SVN.

Snapshots of the sources are packaged every three hours; this change
will be in the next snapshot. You can grab the snapshot at
http://snaps.php.net/.
 
Thank you for the report, and for helping us make PHP better.


 
PHP Copyright © 2001-2024 The PHP Group
All rights reserved.
Last updated: Sat Dec 21 11:01:30 2024 UTC