php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #49532 php5ts.dll access violation exception php5ts!_zend_mm_free_int
Submitted: 2009-09-11 14:14 UTC Modified: 2013-01-08 08:07 UTC
Votes:14
Avg. Score:4.6 ± 0.7
Reproduced:13 of 13 (100.0%)
Same Version:2 (15.4%)
Same OS:10 (76.9%)
From: matroy at investpsp dot ca Assigned: pajoye (profile)
Status: No Feedback Package: *General Issues
PHP Version: 5.2.11 OS: win32 only - Windows 2003 SP2
Private report: No CVE-ID: None
View Developer Edit
Welcome! If you don't have a Git account, you can't do anything here.
If you reported this bug, you can edit this bug over here.
(description)
Block user comment
Status: Assign to:
Package:
Bug Type:
Summary:
From: matroy at investpsp dot ca
New email:
PHP Version: OS:

 

 [2009-09-11 14:14 UTC] matroy at investpsp dot ca
Description:
------------
PHP crashes after running a script in command line for a while. The script is executing the same code in a loop and crashes randomly with a windows event entry like this one: 
------------
Event Type:	Error
Event Source:	Application Error
Event Category:	(100)
Event ID:	1000
Date:		9/11/2009
Time:		9:41:31 AM
User:		N/A
Computer:	STSMTL02
Description:
Faulting application php.exe, version 5.2.6.6, faulting module php5ts.dll, version 5.2.6.6, fault address 0x0000acca.

For more information, see Help and Support Center at http://go.microsoft.com/fwlink/events.asp.
Data:
0000: 41 70 70 6c 69 63 61 74   Applicat
0008: 69 6f 6e 20 46 61 69 6c   ion Fail
0010: 75 72 65 20 20 70 68 70   ure  php
0018: 2e 65 78 65 20 35 2e 32   .exe 5.2
0020: 2e 36 2e 36 20 69 6e 20   .6.6 in 
0028: 70 68 70 35 74 73 2e 64   php5ts.d
0030: 6c 6c 20 35 2e 32 2e 36   ll 5.2.6
0038: 2e 36 20 61 74 20 6f 66   .6 at of
0040: 66 73 65 74 20 30 30 30   fset 000
0048: 30 61 63 63 61            0acca   

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

Here is the crash analysis

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


Type of Analysis Performed   Crash Analysis 
Machine Name   STSMTL02 
Operating System   Windows Server 2003 Service Pack 2 
Number Of Processors   1 
Process ID   4880 
Process Image   c:\Soft\PHP5\php.exe 
System Up-Time   19 day(s) 12:24:24 
Process Up-Time   00:02:25 


Thread 0 - System ID 4228
Entry point   php!mainCRTStartup 
Create time   9/11/2009 9:44:50 AM 
Time spent in user mode   0 Days 0:0:1.312 
Time spent in kernel mode   0 Days 0:0:8.593 






Function     Arg 1     Arg 2     Arg 3   Source 
php5ts!_zend_mm_free_int+1fd     002250f0     00000040     1009b3d9    
php5ts!_efree+39     05b8b3f8     00c0fd78     05ce6b38    
php5ts!zend_hash_destroy+59     05b76dc0     05ce6b38     100ab410    
php5ts!zend_object_std_dtor+2b     05ce6b38     00223b68     00223b68    
php5ts!zend_objects_free_object_storage+10     05ce6b38     00223b68     022d9bd8    
php5ts!zend_objects_store_del_ref_by_handle+140     00000336     00223b68     0244ced8    
php5ts!zend_objects_store_del_ref+19     0244ced8     00223b68     00000000    
php5ts!_zval_dtor_func+77     0244ced8     01a82888     00223b68    
php5ts!ZEND_ASSIGN_DIM_SPEC_VAR_CV_HANDLER+1355     00c0f5e8     00223b68     05d8e864    
php5ts!execute+1c5     0234c088     00223b68     00223b68    
php5ts!zend_do_fcall_common_helper_SPEC+8ca     00c0f690     00223b01     1001c635    
php5ts!ZEND_DO_FCALL_BY_NAME_SPEC_HANDLER+15     00c0f690     00223b68     05addb14    
php5ts!execute+1c5     0234a1a0     00223b68     00223b68    
php5ts!zend_do_fcall_common_helper_SPEC+8ca     00c0f738     00223b01     1001c635    
php5ts!ZEND_DO_FCALL_BY_NAME_SPEC_HANDLER+15     00c0f738     00223b68     05b8ec34    
php5ts!execute+1c5     0234a0c8     00223b68     00223b68    
php5ts!zend_do_fcall_common_helper_SPEC+8ca     00c0f7e0     00223b01     1001c635    
php5ts!ZEND_DO_FCALL_BY_NAME_SPEC_HANDLER+15     00c0f7e0     00223b68     08112234    
php5ts!execute+1c5     023220a0     00223b68     00223b68    
php5ts!zend_do_fcall_common_helper_SPEC+8ca     00c0f888     00223b01     1001c635    
php5ts!ZEND_DO_FCALL_BY_NAME_SPEC_HANDLER+15     00c0f888     00223b68     05bf6054    
php5ts!execute+1c5     02320250     00223b68     00223b68    
php5ts!zend_do_fcall_common_helper_SPEC+8ca     00c0f930     00223b01     1001c635    
php5ts!ZEND_DO_FCALL_BY_NAME_SPEC_HANDLER+15     00c0f930     00223b68     05a4a5c4    
php5ts!execute+1c5     0232aa48     00223b68     00223b68    
php5ts!zend_do_fcall_common_helper_SPEC+8ca     00c0f9d8     00223b01     1001c635    
php5ts!ZEND_DO_FCALL_BY_NAME_SPEC_HANDLER+15     00c0f9d8     00223b68     05a5e6a4    
php5ts!execute+1c5     0232d518     00223b68     00223b68    
php5ts!zend_do_fcall_common_helper_SPEC+8ca     00c0fa80     00223b01     1001c635    
php5ts!ZEND_DO_FCALL_BY_NAME_SPEC_HANDLER+15     00c0fa80     00223b68     01a15514    
php5ts!execute+1c5     0232d690     00223b68     00223b68    
php5ts!zend_do_fcall_common_helper_SPEC+8ca     00c0fb28     00223b01     1001c635    
php5ts!ZEND_DO_FCALL_BY_NAME_SPEC_HANDLER+15     00c0fb28     00223b68     00c0fc2c    
php5ts!execute+1c5     01a0fa58     00223b68     00000000    
php5ts!zend_do_fcall_common_helper_SPEC+8ca     00c0fbd0     00223b01     1001c635    
php5ts!ZEND_DO_FCALL_BY_NAME_SPEC_HANDLER+15     00c0fbd0     00223b68     00223b68    
php5ts!execute+1c5     01a0bd10     00223b68     00000000    
php5ts!zend_execute_scripts+107     00000008     00223b68     00000000    
php5ts!php_execute_script+20d     00c0fec8     00223b68     00000000    
php!main+bca     00000003     00223af8     00222a38    
php!mainCRTStartup+e3     00000000     00000000     7ffd6000    
kernel32!BaseProcessStart+23     00402f72     00000000     00000000    




PHP5TS!_ZEND_MM_FREE_INT+1FDIn php__PID__4880__Date__09_11_2009__Time_09_47_15AM__243__Second_Chance_Exception_C0000005.dmp the assembly instruction at php5ts!_zend_mm_free_int+1fd in c:\Soft\PHP5\php5ts.dll from The PHP Group has caused an access violation exception (0xC0000005) when trying to read from memory location 0x00000000 on thread 0

Module Information 
Image Name: c:\Soft\PHP5\php5ts.dll   Symbol Type:  PDB 
Base address: 0x10000000   Time Stamp:  Wed Jun 17 11:16:31 2009  
Checksum: 0x00000000   Comments:   
COM DLL: False   Company Name:  The PHP Group 
ISAPIExtension: False   File Description:  PHP Script Interpreter 
ISAPIFilter: False   File Version:  5.2.10.10 
Managed DLL: False   Internal Name:  php5ts.dll 
VB DLL: False   Legal Copyright:  Copyright ? 1997-2007 The PHP Group 
Loaded Image Name:  php5ts.dll   Legal Trademarks:  PHP 
Mapped Image Name:  c:\Soft\PHP5\php5ts.dll   Original filename:  php5ts.dll 
Module name:  php5ts   Private Build:   
Single Threaded:  False   Product Name:  PHP Script Interpreter 
Module Size:  4.98 MBytes   Product Version:  5.2.10 
Symbol File Name:  C:\Soft\PHP5DBG\php5ts.pdb   Special Build:  & 




Patches

Pull Requests

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2009-09-11 14:33 UTC] jani@php.net
Please try using this snapshot:

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

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


 [2009-09-11 14:49 UTC] pajoye@php.net
ISAPI is deprecated and not maintained anymore. Please try the same script using the FastCGI interface instead (works with IIS5/6/7).
 [2009-09-11 14:52 UTC] matroy at investpsp dot ca
I'm not using it in a web server, it's as a command line using the php.exe.

I've got the same proble with 5.2.6 and trying with 5.2.11RC3...
 [2009-09-11 18:28 UTC] matroy at investpsp dot ca
Same problem with 5.2.11

Tested with 5.2.11, 5.2.10, 5.2.6

I thought it was due to mssql ext. so I've switched to sqlsrv and still go the crash.

loaded extension are:
php_curl.dll
php_mcrypt.dll
php_mysql.dll
php_sockets.dll
php_zip.dll
php_sqlsrv_ts.dll
 [2009-09-12 11:15 UTC] pajoye@php.net
For what I see in the crashlog, it uses ISAPI. To use PHP with IIS, the recommended way is FastCGI (nts build, non thread safe).

If you are using it only in the command line, please use the NTS (non thread safe) as well.

We also need a script to reproduce the crash.
 [2009-09-20 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".
 [2011-01-11 09:29 UTC] eb at upcl dot univ-lyon1 dot fr
Hello,
I am experiencing quite the same situation though i'm running Apache 2.2 under windows xp sp3. PHP version is 5.3.5.
The weird part of all this is that, right after the installation of PHP, it works fine (no bug), the PHP module interpreting quite well php code. But after rebooting, the apache server fails starting when loading the php module (php5apache2_2.dll) claiming an "application error" due to php5ts.dll module. I installed and uninstalled it twice and each time the same prolem occurred the same way. 
HTTP    : Apache 2.2.17.0
PHP     : 5.3.5.0
Windows : XP SP3
 [2011-01-11 09:55 UTC] pajoye@php.net
-Status: No Feedback +Status: Feedback
 [2011-01-11 09:55 UTC] pajoye@php.net
@eb at upcl dot univ-lyon1 dot fr

Many things can cause this error message.

We still need a way to reproduce it, a small script.
 [2011-01-11 10:52 UTC] eb at upcl dot univ-lyon1 dot fr
Well, actually, adding a line such as "LoadModule php5_module "C:/HD3/apache_php_mysql/software/php/php5apache2_2.dll" in the configuration file of the apache server is enough to lead it failing to start and issuing a "Application défaillante httpd.exe, version 2.2.17.0, module défaillant php5ts.dll, version 5.3.5.0, adresse de défaillance 0x000e890c." in the windows log file. As I told you, this occurs ONLY after the system has rebooted. Right after the installation, all works well.
 [2011-01-11 14:05 UTC] eb at upcl dot univ-lyon1 dot fr
I modify my php.ini file for it expresses error messages. PHP, on loading, claimed beeing unable to load a few modules though available in the appropriate directory; commenting out the loading of these modules in the php file fixed the problem.
These modules were 
; extension=php_oci8.dll
; extension=php_oci8_11g.dll
; extension=php_pdo_oci.dll
; extension=php_sybase_ct.dll
 [2011-03-08 21:49 UTC] mdurovic at gmail dot com
Same issue it happens around 3-5 times a day apache crashes and recycles. I have around 30K page views per day and I can't pin down what causes the error. Any help would be greatly appreciated.  

PHP: 5.2.17
Appache: 5.2.17
OS: Windows 2003 SP2

PHP.ini:

extension=php_curl.dll
extension=php_gd2.dll
extension=php_mbstring.dll
extension=php_mcrypt.dll
extension=php_mysql.dll


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

PHP5TS!_ZEND_MM_FREE_INT+66In httpd__PID__1848__Date__03_08_2011__Time_03_20_11PM__687__Second_Chance_Exception_C0000005.dmp the assembly instruction at php5ts!_zend_mm_free_int+66 in C:\php\php5ts.dll from The PHP Group has caused an access violation exception (0xC0000005) when trying to read from memory location 0x00000000 on thread 148
 [2011-03-08 22:43 UTC] pajoye@php.net
Please try using this snapshot:

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

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

5.3.6RC2 works too.
 [2011-03-10 20:48 UTC] mdurovic at gmail dot com
Same thing with php 5.3.5

In httpd__PID__2316__Date__03_10_2011__Time_02_37_59PM__375__First chance exception 0XC0000005.dmp the assembly instruction at php5ts!_zend_mm_free_int+66 in C:\php\php5ts.dll from The PHP Group has caused an access violation exception (0xC0000005) when trying to read from memory location 0x2b76d478 on thread 100

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

In httpd__PID__2984__Date__03_10_2011__Time_02_26_53PM__375__First chance exception 0XC0000005.dmp the assembly instruction at php5ts!_zend_mm_free_int+66 in C:\php\php5ts.dll from The PHP Group has caused an access violation exception (0xC0000005) when trying to read from memory location 0x00000000 on thread 134
 [2011-03-10 20:52 UTC] mdurovic at gmail dot com
Maybe this will help:

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

httpd__PID__2316__Date__03_10_2011__Time_02_37_59PM__890__Second_Chance_Exception_C0000005.dmp
Type of Analysis Performed   Crash Analysis 
Machine Name   P2134261 
Operating System   Windows Server 2003 Service Pack 2 
Number Of Processors   4 
Process ID   2316 
Process Image   C:\Program Files\Apache Software Foundation\Apache2.2\bin\httpd.exe 
System Up-Time   02:03:45 
Process Up-Time   00:10:58 


Thread 100 - System ID 3012
Entry point   msvcrt!endthreadex+2f 
Create time   3/10/2011 2:27:02 PM 
Time spent in user mode   0 Days 0:0:0.765 
Time spent in kernel mode   0 Days 0:0:0.109 






Function     Arg 1     Arg 2     Arg 3   Source 
php5ts!_zend_mm_free_int+66     117f1028     15bb6a38     00773a64   Zend\zend_alloc.c @ 2018 
php5ts!_efree+36     15bb6a48     117e7710     0089f395   Zend\zend_alloc.c @ 2351 + b 
php5ts!closelog+54     0085a0a7     00000001     00000013   win32\wsyslog.c @ 71 
php5ts!zm_deactivate_syslog+5     00000001     00000013     117e7710   ext\standard\syslog.c @ 122 
php5ts!zm_deactivate_basic+e7     00000001     00000013     117e7710   ext\standard\basic_functions.c @ 3789 
php5ts!module_registry_cleanup+1c     01063558     117e7710     0352faac   Zend\zend_API.c @ 2150 + 11 
php5ts!zend_hash_reverse_apply+42     00bff680     006a8500     117e7710   Zend\zend_hash.c @ 758 + 7 
php5ts!zend_deactivate_modules+62     0352ffa8     00000000     56433230   Zend\zend.c @ 866 + 10 
php5ts!zend_deactivate_modules+48     0ab7b601     00000000     00000005   Zend\zend.c @ 865 + 38 
php5ts!php_end_ob_buffers+26     15bba878     00000b80     117e7710   main\output.c @ 333 + 9 
php5ts!zend_print_zval_ex+50     00756680     00000000     00000000   Zend\zend.c @ 311 
php5ts!zend_print_zval+16     00000005     15bb1bf0     00000001   Zend\zend.c @ 290 + 16 
php5ts!zend_print_variable+c     0352ffa8     00000000     56433230   Zend\zend_variables.c @ 149 + c 
php5ts!php_request_shutdown+13d     00000000     10002ff6     0ab7b620   main\main.c @ 1591 + 3a 
php5apache2_2!php_apache_request_dtor+8     0ab7b620     117e7710     00000004   sapi\apache2handler\sapi_apache2.c @ 508 + 8 
php5apache2_2!php_handler+646     0ab7b620     010112d8     0ab7b620   sapi\apache2handler\sapi_apache2.c @ 681 + 7 
libhttpd!ap_run_handler+21     0ab7b620     6fe7b881     0ab7b620    
libhttpd!ap_invoke_handler+b0     00000000     6fe7b881     0352fee4    
libhttpd!ap_internal_redirect+37     0ab7b5f8     103c9040     00000001    
mod_rewrite+74fb     103c9040     103c9040     103c9040    
libhttpd!ap_run_handler+21     103c9040     103c9040     103c9040    
libhttpd!ap_invoke_handler+b0     6fe7b870     0aad5b68     0352ff3c    
libhttpd!ap_die+29e     103c9040     00000000     005bc0c8    
libhttpd!ap_get_request_note+1d0c     0aad5b68     0aad5b68     0aad5b68    
libhttpd!ap_run_process_connection+21     0aad5b68     006304b0     0352ff84    
libhttpd!ap_process_connection+33     0aad5b68     0aacab30     00000000    
libhttpd!ap_regkey_value_remove+c7c     0aad5b60     00000000     00000000    
msvcrt!endthreadex+a3     017dfa28     00000000     00000000    
kernel32!GetModuleHandleA+df     77bcb4bc     017dfa28     00000000    




PHP5TS!_ZEND_MM_FREE_INT+66In httpd__PID__2316__Date__03_10_2011__Time_02_37_59PM__890__Second_Chance_Exception_C0000005.dmp the assembly instruction at php5ts!_zend_mm_free_int+66 in C:\php\php5ts.dll from The PHP Group has caused an access violation exception (0xC0000005) when trying to read from memory location 0x2b76d478 on thread 100

Module Information 
Image Name: C:\php\php5ts.dll   Symbol Type:  PDB 
Base address: 0x006a0000   Time Stamp:  Thu Jan 06 12:51:58 2011  
Checksum: 0x00000000   Comments:   
COM DLL: False   Company Name:  The PHP Group 
ISAPIExtension: False   File Description:  PHP Script Interpreter 
ISAPIFilter: False   File Version:  5.3.5 
Managed DLL: False   Internal Name:  PHP Script Interpreter 
VB DLL: False   Legal Copyright:  Copyright © 1997-2010 The PHP Group 
Loaded Image Name:  php5ts.dll   Legal Trademarks:  PHP 
Mapped Image Name:  C:\php\php5ts.dll   Original filename:  php5ts.dll 
Module name:  php5ts   Private Build:   
Single Threaded:  False   Product Name:  PHP 
Module Size:  5.57 MBytes   Product Version:  5.3.5 
Symbol File Name:  C:\Documents and Settings\mdurovic\My Documents\Download\php-debug-pack-5.3.5-Win32-VC6-x86\php5ts.pdb   Special Build:  &
 [2011-03-10 21:18 UTC] mdurovic at gmail dot com
I don't know if this helps but here some more info:

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

FAULTING_IP: 
php5ts!_zend_mm_free_int+139 [Zend\zend_alloc.c @ 2019]
006ac699 395f0c          cmp     dword ptr [edi+0Ch],ebx

EXCEPTION_RECORD:  ffffffff -- (.exr 0xffffffffffffffff)
ExceptionAddress: 006ac699 (php5ts!_zend_mm_free_int+0x00000139)
   ExceptionCode: c0000005 (Access violation)
  ExceptionFlags: 00000000
NumberParameters: 2
   Parameter[0]: 00000000
   Parameter[1]: 0000000c
Attempt to read from address 0000000c

PROCESS_NAME:  httpd.exe

ERROR_CODE: (NTSTATUS) 0xc0000005 - The instruction at "0x%08lx" referenced memory at "0x%08lx". The memory could not be "%s".

EXCEPTION_CODE: (NTSTATUS) 0xc0000005 - The instruction at "0x%08lx" referenced memory at "0x%08lx". The memory could not be "%s".

EXCEPTION_PARAMETER1:  00000000

EXCEPTION_PARAMETER2:  0000000c

READ_ADDRESS:  0000000c 

FOLLOWUP_IP: 
php5ts!_zend_mm_free_int+139 [Zend\zend_alloc.c @ 2019]
006ac699 395f0c          cmp     dword ptr [edi+0Ch],ebx

MOD_LIST: <ANALYSIS/>

FAULTING_THREAD:  00001624

BUGCHECK_STR:  APPLICATION_FAULT_NULL_CLASS_PTR_DEREFERENCE_INVALID_POINTER_READ

PRIMARY_PROBLEM_CLASS:  NULL_CLASS_PTR_DEREFERENCE

DEFAULT_BUCKET_ID:  NULL_CLASS_PTR_DEREFERENCE

LAST_CONTROL_TRANSFER:  from 006ad6c6 to 006ac699

STACK_TEXT:  
05bafa38 006ad6c6 01997ba0 00001008 00773a64 php5ts!_zend_mm_free_int+0x139 [Zend\zend_alloc.c @ 2019]
05bafa44 00773a64 05f9b1c8 019967d0 0089f395 php5ts!_efree+0x36 [Zend\zend_alloc.c @ 2351]
05bafa50 0089f395 0085a0a7 00000001 00000013 php5ts!closelog+0x54 [win32\wsyslog.c @ 71]
05bafa54 0085a0a7 00000001 00000013 019967d0 php5ts!zm_deactivate_syslog+0x5 [ext\standard\syslog.c @ 122]
05bafa80 006a851c 00000001 00000013 019967d0 php5ts!zm_deactivate_basic+0xe7 [ext\standard\basic_functions.c @ 3789]
05bafa90 00726b72 01063558 019967d0 05bafb08 php5ts!module_registry_cleanup+0x1c [Zend\zend_API.c @ 2150]
05bafaac 006a2732 00bff680 006a8500 019967d0 php5ts!zend_hash_reverse_apply+0x42 [Zend\zend_hash.c @ 758]
05bafad4 006a2718 05baffa8 00000000 56433230 php5ts!zend_deactivate_modules+0x62 [Zend\zend.c @ 866]
05bafaec 0073f49b 01a0da84 019967d0 0075d1fb php5ts!zend_deactivate_modules+0x48 [Zend\zend.c @ 865]
05bafaf8 0075d1fb 01a0da84 00000000 05bafdd4 php5ts!zend_llist_clean+0xb [Zend\zend_llist.c @ 125]
05bafb20 0075971d 05fab840 0000003c 019967d0 php5ts!php_deactivate_ticks+0x1b [main\php_ticks.c @ 31]
05bafb30 00756699 05fab840 0000003c 77bcac67 php5ts!php_body_write+0x1d [main\output.c @ 118]
05bafb58 00756869 05bafe78 05bafddc 77bcac67 php5ts!php_body_write_wrapper+0x19 [main\main.c @ 1687]
05bafdd4 10003378 00000000 10002ff6 062a3fb8 php5ts!php_execute_script+0xa9 [main\main.c @ 2201]
05bafddc 10002ff6 062a3fb8 019967d0 00000004 php5apache2_2!php_apache_request_dtor+0x8 [sapi\apache2handler\sapi_apache2.c @ 508]
05bafee4 6ff020e1 062a3fb8 010112d8 062a3fb8 php5apache2_2!php_handler+0x646 [sapi\apache2handler\sapi_apache2.c @ 681]
WARNING: Stack unwind information not available. Following frames may be wrong.
05bafefc 6ff02470 062a3fb8 062a3fb8 062a3fb8 libhttpd!ap_run_handler+0x21
05baff14 6ff0eaee 00000000 062a2fd8 05baff3c libhttpd!ap_invoke_handler+0xb0
05baff24 6ff0a96c 062a3fb8 00000000 005bc0c8 libhttpd!ap_die+0x29e
05baff3c 6ff04d61 062a2fd8 062a2fd8 062a2fd8 libhttpd!ap_get_request_note+0x1d0c
05baff54 6ff05023 062a2fd8 0062f400 05baff84 libhttpd!ap_run_process_connection+0x21
05baff64 6ff1d81c 062a2fd8 01bbcda0 00000000 libhttpd!ap_process_connection+0x33
05baff84 77bcb530 062a2fd0 00000000 00000000 libhttpd!ap_regkey_value_remove+0xc7c
05baffb8 77e6482f 017dfbf0 00000000 00000000 msvcrt!_endthreadex+0xa3
05baffec 00000000 77bcb4bc 017dfbf0 00000000 kernel32!BaseThreadStart+0x34


SYMBOL_STACK_INDEX:  0

SYMBOL_NAME:  php5ts!_zend_mm_free_int+139

FOLLOWUP_NAME:  MachineOwner

MODULE_NAME: php5ts

IMAGE_NAME:  php5ts.dll

DEBUG_FLR_IMAGE_TIMESTAMP:  4d26013e

STACK_COMMAND:  ~255s; .ecxr ; kb

FAILURE_BUCKET_ID:  NULL_CLASS_PTR_DEREFERENCE_c0000005_php5ts.dll!_zend_mm_free_int

BUCKET_ID:  APPLICATION_FAULT_NULL_CLASS_PTR_DEREFERENCE_INVALID_POINTER_READ_php5ts!_zend_mm_free_int+139

WATSON_STAGEONE_URL:  http://watson.microsoft.com/StageOne/httpd_exe/2_2_17_0/4cbbe9e8/php5ts_dll/5_3_5_0/4d26013e/c0000005/0000c699.htm?Retriage=1

Followup: MachineOwner
 [2011-03-11 00:28 UTC] pajoye@php.net
Without a script to reproduce your problem we will have no chance to fix it.
 [2011-03-16 13:39 UTC] mdurovic at gmail dot com
It looks like httpd crashes after this error msg in the event viewer.

PHP Fatal error:  Maximum execution time of 30 seconds exceeded in C:\ftproot\LocalUser\linkmarket\framework\common\php\session.class.php on line 71.

That is public function write($id, $data) from the code below:

<?php

class Session
{	
	
	/**
	 * a database connection resource
	 * @var resource
	 */
	private $_sess_db;
	
	/**
	 * Open the session
	 * @return bool
	 */
	public function open() {
		
		if ($this->_sess_db = mysql_connect('server:port',
					'user',
					'pw')) {
			return mysql_select_db('db', $this->_sess_db);
		}
		return false;
		
	}
	
	/**
	 * Close the session
	 * @return bool
	 */
	public function close() {
		
		if(is_resource($this->_sess_db))
		{
			return mysql_close($this->_sess_db);
		}
		
		return false;
	}
	
	/**
	 * Read the session
	 * @param int session id
	 * @return string string of the sessoin
	 */
	public function read($id) {
		
		$id = mysql_real_escape_string($id);
		$sql = sprintf("SELECT data FROM sessions WHERE id = '%s'", $id);
		if ($result = mysql_query($sql, $this->_sess_db))
		{
			if (mysql_num_rows($result))
			{
				$record = mysql_fetch_assoc($result);
				
				//free mysql result
				mysql_free_result($result);
				
				return $record['data'];
			}
		}
		return '';
		
	}
	
	/**
	 * Write the session
	 * @param int session id
	 * @param string data of the session
	 */
	public function write($id, $data) {
		
		$sql = sprintf("REPLACE INTO sessions (id,data,timestamp,ip,url) VALUES('%s', '%s', '%s','%s','%s')",
				mysql_real_escape_string($id),
				mysql_real_escape_string($data),
				mysql_real_escape_string(time()),
				mysql_real_escape_string($_SERVER['REMOTE_ADDR']),
				mysql_real_escape_string("http://".$_SERVER['SERVER_NAME'].$_SERVER['REQUEST_URI']));
				
		return mysql_query($sql, $this->_sess_db);
		
	}
	
	/**
	 * Destoroy the session
	 * @param int session id
	 * @return bool
	 */
	public function destroy($id) {
		
		$sql = sprintf("DELETE FROM sessions WHERE id = '%s'", $id);
		return mysql_query($sql, $this->_sess_db);
		
	}
	
	/**
	 * Garbage Collector
	 * @param int life time (sec.)
	 * @return bool
	 * @see session.gc_divisor      100
	 * @see session.gc_maxlifetime 1440
	 * @see session.gc_probability    1
	 * @usage execution rate 1/100
	 *        (session.gc_probability/session.gc_divisor)
	 */
	public function gc($max) {
		
		$sql = sprintf("DELETE FROM sessions WHERE timestamp < '%s'",
				mysql_real_escape_string(time() - $max));
		return mysql_query($sql, $this->_sess_db);
		
	}
	
}

//ini_set('session.gc_probability', 50);
ini_set('session.save_handler', 'user');

$session = new Session();
session_set_save_handler(array($session, 'open'),
		array($session, 'close'),
		array($session, 'read'),
		array($session, 'write'),
		array($session, 'destroy'),
		array($session, 'gc'));

?>
 [2011-03-18 16:35 UTC] pajoye@php.net
-Assigned To: +Assigned To: pajoye
 [2011-09-02 13:45 UTC] skys dot dragooon dot adsss at gmail dot com
Always the same error.. with 5.3.6 and 5.3.8... :/
 [2011-09-02 14:12 UTC] skys dot dragooon dot adsss at gmail dot com
I solved my problem.
This error occured with php.exe, php-cgi.exe and php-win.exe, and apache's launch..
In my case, it was due to a co-exist of PHP5.2.x and PHP5.3.x version and the bad use by my PHP5.3.x of the PHP5.2.x INI file. (PHPRC environment variable pointing to PHP5.2.x INI that I missed)
 [2013-01-08 08:07 UTC] pajoye@php.net
Please try using this snapshot:

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

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


 [2013-01-08 08:07 UTC] pajoye@php.net
-Status: Feedback +Status: No Feedback
 
PHP Copyright © 2001-2024 The PHP Group
All rights reserved.
Last updated: Thu Dec 26 10:01:29 2024 UTC