Skip to content

Commit 02a2ce7

Browse files
committed
opcache: Call orig_post_shutdown_cb()
This was never called and resulted in this compiler warning: ``` ./ext/opcache/ZendAccelerator.c:3720:15: warning: variable 'orig_post_shutdown_cb' set but not used [-Wunused-but-set-global] 3720 | static void (*orig_post_shutdown_cb)(void); | ^ ```
1 parent 59f8e1d commit 02a2ce7

1 file changed

Lines changed: 5 additions & 0 deletions

File tree

‎ext/opcache/ZendAccelerator.c‎

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3427,6 +3427,11 @@ static void (*orig_post_shutdown_cb)(void);
34273427

34283428
static void accel_post_shutdown(void)
34293429
{
3430+
/* Call original shutdown prior to detaching SHM, so it can access its memory safely. */
3431+
if (orig_post_shutdown_cb) {
3432+
orig_post_shutdown_cb();
3433+
}
3434+
34303435
zend_shared_alloc_shutdown();
34313436
}
34323437

0 commit comments

Comments
 (0)