diff options
author | Dmitry Stogov <dmitry@zend.com> | 2018-11-07 09:36:21 +0300 |
---|---|---|
committer | Dmitry Stogov <dmitry@zend.com> | 2018-11-07 09:36:21 +0300 |
commit | 8c7aa88e2d2ae519160cad7acf220c09ca17f18e (patch) | |
tree | 2de5fd11873a73d5b401d97136c77682c25ae676 | |
parent | bc53642c05f25dcca79a4fa1d2190dda98cd8b61 (diff) | |
download | php-git-8c7aa88e2d2ae519160cad7acf220c09ca17f18e.tar.gz |
Fixed crash introduced by bfaf662ac2e58c16208224f32cb8387a35b3da97
-rw-r--r-- | ext/opcache/Optimizer/block_pass.c | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/ext/opcache/Optimizer/block_pass.c b/ext/opcache/Optimizer/block_pass.c index 34dc008a6d..b36b68dc05 100644 --- a/ext/opcache/Optimizer/block_pass.c +++ b/ext/opcache/Optimizer/block_pass.c @@ -119,6 +119,10 @@ static void strip_nops(zend_op_array *op_array, zend_basic_block *b) strip_leading_nops(op_array, b); } + if (b->len == 0) { + return; + } + /* strip the inside NOPs */ i = j = b->start + 1; while (i < b->start + b->len) { |