]> granicus.if.org Git - php/commitdiff
Fixed bug #77287
authorNikita Popov <nikita.ppv@gmail.com>
Tue, 22 Jan 2019 11:15:06 +0000 (12:15 +0100)
committerNikita Popov <nikita.ppv@gmail.com>
Tue, 22 Jan 2019 11:15:06 +0000 (12:15 +0100)
There may be an EXT_NOP opcode before the parameter list, we should
skip over it.

NEWS
ext/opcache/Optimizer/compact_literals.c

diff --git a/NEWS b/NEWS
index 6265b1736c6d0650fa9c8302eb46f3fd669ad786..656e4ab70eaa9df9a2edf128af39bccd8108589c 100644 (file)
--- a/NEWS
+++ b/NEWS
@@ -61,6 +61,8 @@ PHP                                                                        NEWS
     (Nikita)
   . Fixed bug #77361 (configure fails on 64-bit AIX when opcache enabled).
     (Kevin Adler)
+  . Fixed bug #77287 (Opcache literal compaction is incompatible with EXT
+    opcodes). (Nikita)
 
 - PCRE:
   . Fixed bug #77338 (get_browser with empty string). (Nikita)
index 10bdf540118e5459a6aaed8693c6c4070115ba15..fdab0068a4d5ed41f9e7f96659c08b534d4d07de 100644 (file)
@@ -810,7 +810,7 @@ void zend_optimizer_compact_literals(zend_op_array *op_array, zend_optimizer_ctx
                                                Z_CACHE_SLOT_P(val) = op_array->cache_size;
                                                op_array->cache_size += sizeof(zval);
                                        }
-                               } else if (opline->opcode != ZEND_RECV) {
+                               } else if (opline->opcode != ZEND_RECV && opline->opcode != ZEND_EXT_NOP) {
                                        break;
                                }
                                opline++;