Bug #50918 [Com]: Access violation in php.exe (Bug #49626 redux)

[email protected] ("bugs-php-net at onethumb dot com") Fri, 9 Apr 2010 18:53:44 +0200 (CEST)
Newsgroups php.bugs
Message-ID <[email protected]>
Edit report at http://bugs.php.net/bug.php?id=50918&edit=1

 ID:               50918
 Comment by:       bugs-php-net at onethumb dot com
 Reported by:      hardon at online dot no
 Summary:          Access violation in php.exe (Bug #49626 redux)
 Status:           Assigned
 Type:             Bug
 Package:          Reproducible crash
 Operating System: win32 only - Windows
 PHP Version:      5.3.1
 Assigned To:      pajoye

 New Comment:

I'm experiencing this bug (or something extremely similar) on PHP v5.3.2
on 
CentOS 5.4.

Essentially, if I build PHP with --enable-maintainer-zts (for use with
Apache's 
worker mpm) and try to load any extensions, PHP instantly segfaults at 
/ext/date/php_date.c:844 in guess_timezone() when it tries to call 
DATEG(timezone):

(gdb) run
Starting program: /home/onethumb/zts/php-5.3.2/sapi/cli/php 
[Thread debugging using libthread_db enabled]
[New Thread 0x2b1fea7adc00 (LWP 20681)]

Program received signal SIGSEGV, Segmentation fault.
0x000000000042ab9d in guess_timezone (tzdb=0xea1f60, tsrm_ls=0x1f370500)
at 
/home/onethumb/zts/php-5.3.2/ext/date/php_date.c:844
844             if (DATEG(timezone) && (strlen(DATEG(timezone)) > 0)) {


I have date.timezone properly set in php.ini.  Running without any
extensions 
confirms.  

Hardcoding guess_timezone() to return a valid timezone simply moves the
crash 
farther into php_date, to the next DATEG() call in timezone caching.

Extensions I've tried include very common PECL extensions like zip, apc,
and 
memcached, among others.  Adding any "extension = " line to php.ini
appears to 
trigger this crash.


Previous Comments:
------------------------------------------------------------------------
[2010-03-31 12:31:48] [email protected]

Let me try to give Derick a bt and details about the crash.

------------------------------------------------------------------------
[2010-03-18 09:02:02] progunster at gmail dot com

Well, after reboot I can't reproduce it anymore.
So, what i did:
1.) Installed httpd-2.2.15-win32-x86-openssl-0.9.8m-r2.msi 
It Works!
2.) Changed httpd.conf, to disable http and enable https (also created
self-signed certificates)
3.) Installed PHP from php-5.3.2-Win32-VC6-x86.msi
Right after that httpd.exe was crashing on start. After reboot it all
went gone.
On another computer it was the same.

------------------------------------------------------------------------
[2010-03-17 16:05:53] [email protected]

When does this crash happen exactly? As you seem to be able to reproduce
it, always, I would like to know how :)

------------------------------------------------------------------------
[2010-03-17 15:43:30] progunster at gmail dot com

Added
date.timezone = "Europe/Kiev"
to [Date] section of php.ini, it didn't helped.
Same error, same place.

------------------------------------------------------------------------
[2010-03-17 15:01:48] [email protected]

btw, it is not windows specific, crashes occur on other platform as
well.

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


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=50918


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