php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #57199 PHP crashes on shutdown when APC is active, irrespective of enable_cli option
Submitted: 2006-08-28 14:07 UTC Modified: 2006-08-29 14:30 UTC
From: Jared dot Williams1 at ntlworld dot com Assigned:
Status: Closed Package: APC (PECL)
PHP Version: 5_1 CVS-2006-08-28 OS: Windows 2000
Private report: No CVE-ID: None
Welcome back! If you're the original bug submitter, here's where you can edit the bug or add additional notes.
If you forgot your password, you can retrieve your password here.
Password:
Status:
Package:
Bug Type:
Summary:
From: Jared dot Williams1 at ntlworld dot com
New email:
PHP Version: OS:

 

 [2006-08-28 14:07 UTC] Jared dot Williams1 at ntlworld dot com
Description:
------------
Using PHP 5.1.6 & APC 3.0.11-dev.

Running code from the CLI crashes when APC is loaded. This is irrespective of the apc.enable_cli option.

All options are at their defaults.

apc

APC Support => enabled
Version => 3.0.11-dev
MMAP Support => Disabled
Revision => $Revision: 3.90 $
Build Date => May  4 2006 00:20:07

Directive => Local Value => Master Value
apc.cache_by_default => On => On
apc.enable_cli => On => On
apc.enabled => On => On
apc.file_update_protection => 2 => 2
apc.filters => no value => no value
apc.gc_ttl => 3600 => 3600
apc.max_file_size => 1M => 1M
apc.num_files_hint => 1000 => 1000
apc.optimization => Off => Off
apc.shm_segments => 1 => 1
apc.shm_size => 30 => 30
apc.slam_defense => Off => Off
apc.stat => On => On
apc.ttl => 0 => 0
apc.user_entries_hint => 100 => 100
apc.user_ttl => 0 => 0


Reproduce code:
---------------
php -r "echo phpversion(), chr(10), phpversion('apc');"

Expected result:
----------------
5.1.6
3.0.11-dev

Actual result:
--------------
5.1.6
3.0.11-dev

Follow by an application exception

---------------------------
php.exe - Application Error
---------------------------
The instruction at "0x011582a0" referenced memory at "0x011582a0". The memory could not be "read".


Click on OK to terminate the program
Click on CANCEL to debug the program
---------------------------
OK   Cancel   
---------------------------


Patches

Pull Requests

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2006-08-29 12:08 UTC] gopalv82 at yahoo dot com
This is because apc.so is dlclosed before the TSRM calls the php_apc_shutdown_globals from tsrm_shutdown. The function pointer in the ->dtor is invalid because the shared object was unloaded.
 [2006-08-29 12:20 UTC] gopalv82 at yahoo dot com
Please retest with current CVS head of APC, or apply

http://cvs.php.net/viewvc.cgi/pecl/apc/php_apc.c?r1=3.100&r2=3.101&view=patch

confirm fix.
 [2006-08-29 14:30 UTC] Jared dot Williams1 at ntlworld dot com
I can confirm this does solve the shutdown crash.

apc

APC Support => enabled
Version => 3.0.12-dev
MMAP Support => Disabled
Revision => $Revision: 3.101 $
Build Date => Aug 29 2006 19:18:34
 
PHP Copyright © 2001-2025 The PHP Group
All rights reserved.
Last updated: Sat Jul 12 02:01:35 2025 UTC