mirror of
https://github.com/php/php-src.git
synced 2026-04-29 03:03:26 +02:00
Tracing JIT: Fixed possible stack-buffer-overflow.
This commit is contained in:
@@ -350,7 +350,7 @@ ZEND_OPCODE_HANDLER_RET ZEND_FASTCALL zend_jit_loop_trace_helper(ZEND_OPCODE_HAN
|
||||
trace_buffer[idx].info = _op | (_info); \
|
||||
trace_buffer[idx].ptr = _ptr; \
|
||||
idx++; \
|
||||
if (idx >= ZEND_JIT_TRACE_MAX_LENGTH - 1) { \
|
||||
if (idx >= ZEND_JIT_TRACE_MAX_LENGTH - 2) { \
|
||||
stop = ZEND_JIT_TRACE_STOP_TOO_LONG; \
|
||||
break; \
|
||||
}
|
||||
@@ -362,7 +362,7 @@ ZEND_OPCODE_HANDLER_RET ZEND_FASTCALL zend_jit_loop_trace_helper(ZEND_OPCODE_HAN
|
||||
trace_buffer[idx].op3_type = _op3_type; \
|
||||
trace_buffer[idx].ptr = _ptr; \
|
||||
idx++; \
|
||||
if (idx >= ZEND_JIT_TRACE_MAX_LENGTH - 1) { \
|
||||
if (idx >= ZEND_JIT_TRACE_MAX_LENGTH - 2) { \
|
||||
stop = ZEND_JIT_TRACE_STOP_TOO_LONG; \
|
||||
break; \
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user