Skip to content

Commit 3d832fc

Browse files
committed
Merge branch 'PHP-8.3'
* PHP-8.3: Fixed GH-12494: Zend/tests/arginfo_zpp_mismatch.phpt causes a segfault withJIT + --repeat 2
2 parents 8f8b5ba + a1818dd commit 3d832fc

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

ext/opcache/zend_shared_alloc.c

+1-1
Original file line numberDiff line numberDiff line change
@@ -281,7 +281,7 @@ int zend_shared_alloc_startup(size_t requested_size, size_t reserved_size)
281281
free(ZSMMG(shared_segments));
282282
ZSMMG(shared_segments) = tmp_shared_segments;
283283

284-
ZSMMG(shared_memory_state).positions = (int *)zend_shared_alloc(sizeof(int) * ZSMMG(shared_segments_count));
284+
ZSMMG(shared_memory_state).positions = (size_t *)zend_shared_alloc(sizeof(size_t) * ZSMMG(shared_segments_count));
285285
if (!ZSMMG(shared_memory_state).positions) {
286286
zend_accel_error_noreturn(ACCEL_LOG_FATAL, "Insufficient shared memory!");
287287
return ALLOC_FAILURE;

ext/opcache/zend_shared_alloc.h

+1-1
Original file line numberDiff line numberDiff line change
@@ -95,7 +95,7 @@ typedef struct _handler_entry {
9595
} zend_shared_memory_handler_entry;
9696

9797
typedef struct _zend_shared_memory_state {
98-
int *positions; /* current positions for each segment */
98+
size_t *positions; /* current positions for each segment */
9999
size_t shared_free; /* amount of free shared memory */
100100
} zend_shared_memory_state;
101101

0 commit comments

Comments
 (0)