diff options
author | Anatol Belski <ab@php.net> | 2014-12-13 19:43:45 +0100 |
---|---|---|
committer | Anatol Belski <ab@php.net> | 2014-12-13 19:43:45 +0100 |
commit | bb66f385d09e7e55390e9f57fcbca08f6b43ff91 (patch) | |
tree | 54defb44e55c1ebc0afa15aa60758d87a4b9ce3b /Zend/zend_execute.c | |
parent | dfb18b1188492efa48ade07029172c5535f65f93 (diff) | |
parent | 0ea0b591d79ae0ee18d33533a5c701330836ff6b (diff) | |
download | php-git-bb66f385d09e7e55390e9f57fcbca08f6b43ff91.tar.gz |
Merge remote-tracking branch 'origin/master' into native-tls
* origin/master: (37 commits)
NEWS
NEWS
Fix bug #68601 buffer read overflow in gd_gif_in.c
Fixed compilation warnings
Removed unnecessary checks
pcntl_signal_dispatch: Speed up by preventing system calls when unnecessary
Merged PR #911.
Removed ZEND_ACC_FINAL_CLASS which is unnecessary. This also fixed some currently defined classes as final which were just not being considered as such before.
Updated NEWS
Updated NEWS
Updated NEWS
Fix bug #68532: convert.base64-encode omits padding bytes
Updated NEWS
Updated NEWS
Updated NEWS
Fixed Bug #65576 (Constructor from trait conflicts with inherited constructor)
Updated NEWS
Updated NEWS
Fix MySQLi tests
Fixed gd test
...
Diffstat (limited to 'Zend/zend_execute.c')
-rw-r--r-- | Zend/zend_execute.c | 18 |
1 files changed, 9 insertions, 9 deletions
diff --git a/Zend/zend_execute.c b/Zend/zend_execute.c index aff92a3952..0a156f84a4 100644 --- a/Zend/zend_execute.c +++ b/Zend/zend_execute.c @@ -1168,7 +1168,7 @@ str_index: return retval; } -static zend_never_inline zend_long zend_check_string_offset(zval *container, zval *dim, int type TSRMLS_DC) +static zend_never_inline zend_long zend_check_string_offset(zval *dim, int type TSRMLS_DC) { zend_long offset; @@ -1211,7 +1211,7 @@ try_again: static zend_always_inline zend_long zend_fetch_string_offset(zval *container, zval *dim, int type TSRMLS_DC) { - zend_long offset = zend_check_string_offset(container, dim, type TSRMLS_CC); + zend_long offset = zend_check_string_offset(dim, type TSRMLS_CC); if (Z_REFCOUNTED_P(container)) { if (Z_REFCOUNT_P(container) > 1) { @@ -1250,7 +1250,7 @@ convert_to_array: goto fetch_from_array; } - zend_check_string_offset(container, dim, type TSRMLS_CC); + zend_check_string_offset(dim, type TSRMLS_CC); ZVAL_INDIRECT(result, NULL); /* wrong string offset */ } else if (EXPECTED(Z_TYPE_P(container) == IS_OBJECT)) { @@ -1666,12 +1666,12 @@ static zend_always_inline void i_init_func_execute_data(zend_execute_data *execu } while (var != end); } - if (op_array->this_var != -1 && Z_OBJ(EX(This))) { + if (op_array->this_var != (uint32_t)-1 && EXPECTED(Z_OBJ(EX(This)))) { ZVAL_OBJ(EX_VAR(op_array->this_var), Z_OBJ(EX(This))); GC_REFCOUNT(Z_OBJ(EX(This)))++; } - if (!op_array->run_time_cache && op_array->last_cache_slot) { + if (UNEXPECTED(!op_array->run_time_cache)) { op_array->run_time_cache = zend_arena_calloc(&CG(arena), op_array->last_cache_slot, sizeof(void*)); } EX_LOAD_RUN_TIME_CACHE(op_array); @@ -1691,12 +1691,12 @@ static zend_always_inline void i_init_code_execute_data(zend_execute_data *execu zend_attach_symbol_table(execute_data); - if (op_array->this_var != -1 && Z_OBJ(EX(This))) { + if (op_array->this_var != (uint32_t)-1 && EXPECTED(Z_OBJ(EX(This)))) { ZVAL_OBJ(EX_VAR(op_array->this_var), Z_OBJ(EX(This))); GC_REFCOUNT(Z_OBJ(EX(This)))++; } - if (!op_array->run_time_cache && op_array->last_cache_slot) { + if (!op_array->run_time_cache) { op_array->run_time_cache = ecalloc(op_array->last_cache_slot, sizeof(void*)); } EX_LOAD_RUN_TIME_CACHE(op_array); @@ -1762,12 +1762,12 @@ static zend_always_inline void i_init_execute_data(zend_execute_data *execute_da } } - if (op_array->this_var != -1 && Z_OBJ(EX(This))) { + if (op_array->this_var != (uint32_t)-1 && EXPECTED(Z_OBJ(EX(This)))) { ZVAL_OBJ(EX_VAR(op_array->this_var), Z_OBJ(EX(This))); GC_REFCOUNT(Z_OBJ(EX(This)))++; } - if (!op_array->run_time_cache && op_array->last_cache_slot) { + if (!op_array->run_time_cache) { if (op_array->function_name) { op_array->run_time_cache = zend_arena_calloc(&CG(arena), op_array->last_cache_slot, sizeof(void*)); } else { |