mirror of
https://github.com/php/php-src.git
synced 2025-08-15 21:48:51 +02:00
Use the new 'ZSTR' macros in the rest of the code.
Does not change anything to the generated code (thanks to compat macros) but cleaner.
This commit is contained in:
parent
b352643910
commit
d96eab8d79
41 changed files with 194 additions and 195 deletions
|
@ -1653,7 +1653,7 @@ ZEND_API int array_set_zval_key(HashTable *ht, zval *key, zval *value) /* {{{ */
|
|||
result = zend_symtable_update(ht, Z_STR_P(key), value);
|
||||
break;
|
||||
case IS_NULL:
|
||||
result = zend_symtable_update(ht, STR_EMPTY_ALLOC(), value);
|
||||
result = zend_symtable_update(ht, ZSTR_EMPTY_ALLOC(), value);
|
||||
break;
|
||||
case IS_RESOURCE:
|
||||
zend_error(E_NOTICE, "Resource ID#" ZEND_LONG_FMT " used as offset, casting to integer (%pd)", Z_RES_HANDLE_P(key), Z_RES_HANDLE_P(key));
|
||||
|
@ -2842,7 +2842,7 @@ static int zend_is_callable_check_class(zend_string *name, zend_fcall_info_cache
|
|||
zend_string *lcname;
|
||||
ALLOCA_FLAG(use_heap);
|
||||
|
||||
STR_ALLOCA_ALLOC(lcname, name_len, use_heap);
|
||||
ZSTR_ALLOCA_ALLOC(lcname, name_len, use_heap);
|
||||
zend_str_tolower_copy(lcname->val, name->val, name_len);
|
||||
|
||||
*strict_class = 0;
|
||||
|
@ -2913,7 +2913,7 @@ static int zend_is_callable_check_class(zend_string *name, zend_fcall_info_cache
|
|||
} else {
|
||||
if (error) zend_spprintf(error, 0, "class '%.*s' not found", name_len, name->val);
|
||||
}
|
||||
STR_ALLOCA_FREE(lcname, use_heap);
|
||||
ZSTR_ALLOCA_FREE(lcname, use_heap);
|
||||
return ret;
|
||||
}
|
||||
/* }}} */
|
||||
|
@ -2943,7 +2943,7 @@ static int zend_is_callable_check_func(int check_flags, zval *callable, zend_fca
|
|||
|
||||
/* Skip leading \ */
|
||||
if (UNEXPECTED(Z_STRVAL_P(callable)[0] == '\\')) {
|
||||
STR_ALLOCA_INIT(lmname, Z_STRVAL_P(callable) + 1, Z_STRLEN_P(callable) - 1, use_heap);
|
||||
ZSTR_ALLOCA_INIT(lmname, Z_STRVAL_P(callable) + 1, Z_STRLEN_P(callable) - 1, use_heap);
|
||||
} else {
|
||||
lmname = Z_STR_P(callable);
|
||||
}
|
||||
|
@ -2951,23 +2951,23 @@ static int zend_is_callable_check_func(int check_flags, zval *callable, zend_fca
|
|||
* This may be a compound name that includes namespace name */
|
||||
if (EXPECTED((fcc->function_handler = zend_hash_find_ptr(EG(function_table), lmname)) != NULL)) {
|
||||
if (lmname != Z_STR_P(callable)) {
|
||||
STR_ALLOCA_FREE(lmname, use_heap);
|
||||
ZSTR_ALLOCA_FREE(lmname, use_heap);
|
||||
}
|
||||
return 1;
|
||||
} else {
|
||||
if (lmname == Z_STR_P(callable)) {
|
||||
STR_ALLOCA_INIT(lmname, Z_STRVAL_P(callable), Z_STRLEN_P(callable), use_heap);
|
||||
ZSTR_ALLOCA_INIT(lmname, Z_STRVAL_P(callable), Z_STRLEN_P(callable), use_heap);
|
||||
} else {
|
||||
zend_string_forget_hash_val(lmname);
|
||||
}
|
||||
zend_str_tolower(lmname->val, lmname->len);
|
||||
if ((fcc->function_handler = zend_hash_find_ptr(EG(function_table), lmname)) != NULL) {
|
||||
STR_ALLOCA_FREE(lmname, use_heap);
|
||||
ZSTR_ALLOCA_FREE(lmname, use_heap);
|
||||
return 1;
|
||||
}
|
||||
}
|
||||
if (lmname != Z_STR_P(callable)) {
|
||||
STR_ALLOCA_FREE(lmname, use_heap);
|
||||
ZSTR_ALLOCA_FREE(lmname, use_heap);
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
@ -188,7 +188,7 @@ static int zend_ast_add_array_element(zval *result, zval *offset, zval *expr)
|
|||
zval_dtor(offset);
|
||||
break;
|
||||
case IS_NULL:
|
||||
zend_symtable_update(Z_ARRVAL_P(result), STR_EMPTY_ALLOC(), expr);
|
||||
zend_symtable_update(Z_ARRVAL_P(result), ZSTR_EMPTY_ALLOC(), expr);
|
||||
break;
|
||||
case IS_LONG:
|
||||
zend_hash_index_update(Z_ARRVAL_P(result), Z_LVAL_P(offset), expr);
|
||||
|
|
|
@ -413,7 +413,7 @@ static inline void zend_insert_literal(zend_op_array *op_array, zval *zv, int li
|
|||
if (Z_TYPE_P(zv) == IS_STRING || Z_TYPE_P(zv) == IS_CONSTANT) {
|
||||
zend_string_hash_val(Z_STR_P(zv));
|
||||
Z_STR_P(zv) = zend_new_interned_string(Z_STR_P(zv));
|
||||
if (IS_INTERNED(Z_STR_P(zv))) {
|
||||
if (ZSTR_IS_INTERNED(Z_STR_P(zv))) {
|
||||
Z_TYPE_FLAGS_P(zv) &= ~ (IS_TYPE_REFCOUNTED | IS_TYPE_COPYABLE);
|
||||
}
|
||||
}
|
||||
|
@ -725,10 +725,10 @@ void *zend_hash_find_ptr_lc(HashTable *ht, const char *str, size_t len) {
|
|||
zend_string *lcname;
|
||||
ALLOCA_FLAG(use_heap);
|
||||
|
||||
STR_ALLOCA_ALLOC(lcname, len, use_heap);
|
||||
ZSTR_ALLOCA_ALLOC(lcname, len, use_heap);
|
||||
zend_str_tolower_copy(lcname->val, str, len);
|
||||
result = zend_hash_find_ptr(ht, lcname);
|
||||
STR_ALLOCA_FREE(lcname, use_heap);
|
||||
ZSTR_ALLOCA_FREE(lcname, use_heap);
|
||||
|
||||
return result;
|
||||
}
|
||||
|
@ -5708,7 +5708,7 @@ static zend_bool zend_try_ct_eval_array(zval *result, zend_ast *ast) /* {{{ */
|
|||
zend_hash_index_update(Z_ARRVAL_P(result), 1, value);
|
||||
break;
|
||||
case IS_NULL:
|
||||
zend_hash_update(Z_ARRVAL_P(result), STR_EMPTY_ALLOC(), value);
|
||||
zend_hash_update(Z_ARRVAL_P(result), ZSTR_EMPTY_ALLOC(), value);
|
||||
break;
|
||||
default:
|
||||
zend_error_noreturn(E_COMPILE_ERROR, "Illegal offset type");
|
||||
|
|
|
@ -673,7 +673,7 @@ ZEND_METHOD(exception, __toString)
|
|||
|
||||
DEFAULT_0_PARAMS;
|
||||
|
||||
str = STR_EMPTY_ALLOC();
|
||||
str = ZSTR_EMPTY_ALLOC();
|
||||
|
||||
exception = getThis();
|
||||
ZVAL_STRINGL(&fname, "gettraceasstring", sizeof("gettraceasstring")-1);
|
||||
|
|
|
@ -573,9 +573,9 @@ ZEND_API char * zend_verify_internal_arg_class_kind(const zend_internal_arg_info
|
|||
zend_string *key;
|
||||
ALLOCA_FLAG(use_heap);
|
||||
|
||||
STR_ALLOCA_INIT(key, cur_arg_info->class_name, strlen(cur_arg_info->class_name), use_heap);
|
||||
ZSTR_ALLOCA_INIT(key, cur_arg_info->class_name, strlen(cur_arg_info->class_name), use_heap);
|
||||
*pce = zend_fetch_class(key, (ZEND_FETCH_CLASS_AUTO | ZEND_FETCH_CLASS_NO_AUTOLOAD));
|
||||
STR_ALLOCA_FREE(key, use_heap);
|
||||
ZSTR_ALLOCA_FREE(key, use_heap);
|
||||
|
||||
*class_name = (*pce) ? (*pce)->name->val : (char*)cur_arg_info->class_name;
|
||||
if (*pce && (*pce)->ce_flags & ZEND_ACC_INTERFACE) {
|
||||
|
@ -1564,7 +1564,7 @@ str_index:
|
|||
} else {
|
||||
switch (Z_TYPE_P(dim)) {
|
||||
case IS_NULL:
|
||||
offset_key = STR_EMPTY_ALLOC();
|
||||
offset_key = ZSTR_EMPTY_ALLOC();
|
||||
goto str_index;
|
||||
case IS_DOUBLE:
|
||||
hval = zend_dval_to_lval(Z_DVAL_P(dim));
|
||||
|
|
|
@ -524,7 +524,7 @@ add_to_hash:
|
|||
zend_hash_iterators_update(ht, HT_INVALID_IDX, idx);
|
||||
p = ht->arData + idx;
|
||||
p->key = key;
|
||||
if (!IS_INTERNED(key)) {
|
||||
if (!ZSTR_IS_INTERNED(key)) {
|
||||
zend_string_addref(key);
|
||||
ht->u.flags &= ~HASH_FLAG_STATIC_KEYS;
|
||||
zend_string_hash_val(key);
|
||||
|
|
|
@ -894,7 +894,7 @@ static zend_always_inline zval *_zend_hash_append(HashTable *ht, zend_string *ke
|
|||
Bucket *p = ht->arData + idx;
|
||||
|
||||
ZVAL_COPY_VALUE(&p->val, zv);
|
||||
if (!IS_INTERNED(key)) {
|
||||
if (!ZSTR_IS_INTERNED(key)) {
|
||||
ht->u.flags &= ~HASH_FLAG_STATIC_KEYS;
|
||||
zend_string_addref(key);
|
||||
zend_string_hash_val(key);
|
||||
|
@ -916,7 +916,7 @@ static zend_always_inline zval *_zend_hash_append_ptr(HashTable *ht, zend_string
|
|||
Bucket *p = ht->arData + idx;
|
||||
|
||||
ZVAL_PTR(&p->val, ptr);
|
||||
if (!IS_INTERNED(key)) {
|
||||
if (!ZSTR_IS_INTERNED(key)) {
|
||||
ht->u.flags &= ~HASH_FLAG_STATIC_KEYS;
|
||||
zend_string_addref(key);
|
||||
zend_string_hash_val(key);
|
||||
|
@ -938,7 +938,7 @@ static zend_always_inline void _zend_hash_append_ind(HashTable *ht, zend_string
|
|||
Bucket *p = ht->arData + idx;
|
||||
|
||||
ZVAL_INDIRECT(&p->val, ptr);
|
||||
if (!IS_INTERNED(key)) {
|
||||
if (!ZSTR_IS_INTERNED(key)) {
|
||||
ht->u.flags &= ~HASH_FLAG_STATIC_KEYS;
|
||||
zend_string_addref(key);
|
||||
zend_string_hash_val(key);
|
||||
|
|
|
@ -1014,7 +1014,7 @@ exit_expr:
|
|||
|
||||
backticks_expr:
|
||||
/* empty */
|
||||
{ $$ = zend_ast_create_zval_from_str(STR_EMPTY_ALLOC()); }
|
||||
{ $$ = zend_ast_create_zval_from_str(ZSTR_EMPTY_ALLOC()); }
|
||||
| T_ENCAPSED_AND_WHITESPACE { $$ = $1; }
|
||||
| encaps_list { $$ = $1; }
|
||||
;
|
||||
|
@ -1045,7 +1045,7 @@ scalar:
|
|||
| T_CLASS_C { $$ = zend_ast_create_ex(ZEND_AST_MAGIC_CONST, T_CLASS_C); }
|
||||
| T_START_HEREDOC T_ENCAPSED_AND_WHITESPACE T_END_HEREDOC { $$ = $2; }
|
||||
| T_START_HEREDOC T_END_HEREDOC
|
||||
{ $$ = zend_ast_create_zval_from_str(STR_EMPTY_ALLOC()); }
|
||||
{ $$ = zend_ast_create_zval_from_str(ZSTR_EMPTY_ALLOC()); }
|
||||
| '"' encaps_list '"' { $$ = $2; }
|
||||
| T_START_HEREDOC encaps_list T_END_HEREDOC { $$ = $2; }
|
||||
| dereferencable_scalar { $$ = $1; }
|
||||
|
|
|
@ -1048,7 +1048,7 @@ ZEND_API zend_function *zend_get_call_trampoline_func(zend_class_entry *ce, zend
|
|||
|
||||
func->prototype = fbc;
|
||||
func->scope = fbc->common.scope;
|
||||
func->filename = (fbc->type == ZEND_USER_FUNCTION)? fbc->op_array.filename : STR_EMPTY_ALLOC();
|
||||
func->filename = (fbc->type == ZEND_USER_FUNCTION)? fbc->op_array.filename : ZSTR_EMPTY_ALLOC();
|
||||
func->line_start = (fbc->type == ZEND_USER_FUNCTION)? fbc->op_array.line_start : 0;
|
||||
func->line_end = (fbc->type == ZEND_USER_FUNCTION)? fbc->op_array.line_end : 0;
|
||||
|
||||
|
@ -1084,13 +1084,13 @@ static union _zend_function *zend_std_get_method(zend_object **obj_ptr, zend_str
|
|||
use_heap = 0;
|
||||
#endif
|
||||
} else {
|
||||
STR_ALLOCA_ALLOC(lc_method_name, method_name->len, use_heap);
|
||||
ZSTR_ALLOCA_ALLOC(lc_method_name, method_name->len, use_heap);
|
||||
zend_str_tolower_copy(lc_method_name->val, method_name->val, method_name->len);
|
||||
}
|
||||
|
||||
if (UNEXPECTED((func = zend_hash_find(&zobj->ce->function_table, lc_method_name)) == NULL)) {
|
||||
if (UNEXPECTED(!key)) {
|
||||
STR_ALLOCA_FREE(lc_method_name, use_heap);
|
||||
ZSTR_ALLOCA_FREE(lc_method_name, use_heap);
|
||||
}
|
||||
if (zobj->ce->__call) {
|
||||
return zend_get_user_call_function(zobj->ce, method_name);
|
||||
|
@ -1149,7 +1149,7 @@ static union _zend_function *zend_std_get_method(zend_object **obj_ptr, zend_str
|
|||
}
|
||||
|
||||
if (UNEXPECTED(!key)) {
|
||||
STR_ALLOCA_FREE(lc_method_name, use_heap);
|
||||
ZSTR_ALLOCA_FREE(lc_method_name, use_heap);
|
||||
}
|
||||
return fbc;
|
||||
}
|
||||
|
|
|
@ -803,7 +803,7 @@ try_again:
|
|||
case IS_UNDEF:
|
||||
case IS_NULL:
|
||||
case IS_FALSE:
|
||||
return STR_EMPTY_ALLOC();
|
||||
return ZSTR_EMPTY_ALLOC();
|
||||
case IS_TRUE:
|
||||
return zend_string_init("1", 1, 0);
|
||||
case IS_RESOURCE: {
|
||||
|
@ -838,7 +838,7 @@ try_again:
|
|||
zval_ptr_dtor(z);
|
||||
}
|
||||
zend_error(EG(exception) ? E_ERROR : E_RECOVERABLE_ERROR, "Object of class %s could not be converted to string", Z_OBJCE_P(op)->name->val);
|
||||
return STR_EMPTY_ALLOC();
|
||||
return ZSTR_EMPTY_ALLOC();
|
||||
}
|
||||
case IS_REFERENCE:
|
||||
op = Z_REFVAL_P(op);
|
||||
|
|
|
@ -19,7 +19,7 @@
|
|||
#include <zend.h>
|
||||
#include "zend_smart_str_public.h"
|
||||
|
||||
#define SMART_STR_OVERHEAD (ZEND_MM_OVERHEAD + _STR_HEADER_SIZE)
|
||||
#define SMART_STR_OVERHEAD (ZEND_MM_OVERHEAD + _ZSTR_HEADER_SIZE)
|
||||
|
||||
#ifndef SMART_STR_PAGE
|
||||
# define SMART_STR_PAGE 4096
|
||||
|
@ -42,7 +42,7 @@ ZEND_API void ZEND_FASTCALL smart_str_erealloc(smart_str *str, size_t len)
|
|||
str->s->len = 0;
|
||||
} else {
|
||||
str->a = SMART_STR_NEW_SIZE(len);
|
||||
str->s = (zend_string *) erealloc2(str->s, _STR_HEADER_SIZE + str->a + 1, _STR_HEADER_SIZE + str->s->len + 1);
|
||||
str->s = (zend_string *) erealloc2(str->s, _ZSTR_HEADER_SIZE + str->a + 1, _ZSTR_HEADER_SIZE + str->s->len + 1);
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -56,6 +56,6 @@ ZEND_API void ZEND_FASTCALL smart_str_realloc(smart_str *str, size_t len)
|
|||
str->s->len = 0;
|
||||
} else {
|
||||
str->a = SMART_STR_NEW_SIZE(len);
|
||||
str->s = (zend_string *) realloc(str->s, _STR_HEADER_SIZE + str->a + 1);
|
||||
str->s = (zend_string *) realloc(str->s, _ZSTR_HEADER_SIZE + str->a + 1);
|
||||
}
|
||||
}
|
||||
|
|
|
@ -83,7 +83,7 @@ static zend_string *zend_new_interned_string_int(zend_string *str)
|
|||
uint idx;
|
||||
Bucket *p;
|
||||
|
||||
if (IS_INTERNED(str)) {
|
||||
if (ZSTR_IS_INTERNED(str)) {
|
||||
return str;
|
||||
}
|
||||
|
||||
|
|
|
@ -279,7 +279,7 @@ ZEND_VM_HANDLER(8, ZEND_CONCAT, CONST|TMPVAR|CV, CONST|TMPVAR|CV)
|
|||
}
|
||||
}
|
||||
if (OP1_TYPE != IS_CONST && OP1_TYPE != IS_CV &&
|
||||
!IS_INTERNED(op1_str) && GC_REFCOUNT(op1_str) == 1) {
|
||||
!ZSTR_IS_INTERNED(op1_str) && GC_REFCOUNT(op1_str) == 1) {
|
||||
size_t len = op1_str->len;
|
||||
|
||||
str = zend_string_realloc(op1_str, len + op2_str->len, 0);
|
||||
|
@ -5281,7 +5281,7 @@ ZEND_VM_C_LABEL(num_index):
|
|||
offset = Z_REFVAL_P(offset);
|
||||
ZEND_VM_C_GOTO(add_again);
|
||||
} else if (Z_TYPE_P(offset) == IS_NULL) {
|
||||
str = STR_EMPTY_ALLOC();
|
||||
str = ZSTR_EMPTY_ALLOC();
|
||||
ZEND_VM_C_GOTO(str_index);
|
||||
} else if (Z_TYPE_P(offset) == IS_DOUBLE) {
|
||||
hval = zend_dval_to_lval(Z_DVAL_P(offset));
|
||||
|
@ -5294,7 +5294,7 @@ ZEND_VM_C_LABEL(num_index):
|
|||
ZEND_VM_C_GOTO(num_index);
|
||||
} else if (OP2_TYPE == IS_CV && Z_TYPE_P(offset) == IS_UNDEF) {
|
||||
GET_OP2_UNDEF_CV(offset, BP_VAR_R);
|
||||
str = STR_EMPTY_ALLOC();
|
||||
str = ZSTR_EMPTY_ALLOC();
|
||||
ZEND_VM_C_GOTO(str_index);
|
||||
} else {
|
||||
zend_error(E_WARNING, "Illegal offset type");
|
||||
|
@ -5709,7 +5709,7 @@ ZEND_VM_C_LABEL(num_index_dim):
|
|||
hval = zend_dval_to_lval(Z_DVAL_P(offset));
|
||||
ZEND_VM_C_GOTO(num_index_dim);
|
||||
} else if (Z_TYPE_P(offset) == IS_NULL) {
|
||||
key = STR_EMPTY_ALLOC();
|
||||
key = ZSTR_EMPTY_ALLOC();
|
||||
ZEND_VM_C_GOTO(str_index_dim);
|
||||
} else if (Z_TYPE_P(offset) == IS_FALSE) {
|
||||
hval = 0;
|
||||
|
@ -5722,7 +5722,7 @@ ZEND_VM_C_LABEL(num_index_dim):
|
|||
ZEND_VM_C_GOTO(num_index_dim);
|
||||
} else if (OP2_TYPE == IS_CV && Z_TYPE_P(offset) == IS_UNDEF) {
|
||||
GET_OP2_UNDEF_CV(offset, BP_VAR_R);
|
||||
key = STR_EMPTY_ALLOC();
|
||||
key = ZSTR_EMPTY_ALLOC();
|
||||
ZEND_VM_C_GOTO(str_index_dim);
|
||||
} else {
|
||||
zend_error(E_WARNING, "Illegal offset type in unset");
|
||||
|
@ -6604,7 +6604,7 @@ ZEND_VM_C_LABEL(num_index_prop):
|
|||
hval = zend_dval_to_lval(Z_DVAL_P(offset));
|
||||
ZEND_VM_C_GOTO(num_index_prop);
|
||||
} else if (Z_TYPE_P(offset) == IS_NULL) {
|
||||
str = STR_EMPTY_ALLOC();
|
||||
str = ZSTR_EMPTY_ALLOC();
|
||||
ZEND_VM_C_GOTO(str_index_prop);
|
||||
} else if (Z_TYPE_P(offset) == IS_FALSE) {
|
||||
hval = 0;
|
||||
|
@ -6617,7 +6617,7 @@ ZEND_VM_C_LABEL(num_index_prop):
|
|||
ZEND_VM_C_GOTO(num_index_prop);
|
||||
} else if (OP2_TYPE == IS_CV && Z_TYPE_P(offset) == IS_UNDEF) {
|
||||
GET_OP2_UNDEF_CV(offset, BP_VAR_R);
|
||||
str = STR_EMPTY_ALLOC();
|
||||
str = ZSTR_EMPTY_ALLOC();
|
||||
ZEND_VM_C_GOTO(str_index_prop);
|
||||
} else {
|
||||
zend_error(E_WARNING, "Illegal offset type in isset or empty");
|
||||
|
|
|
@ -4735,7 +4735,7 @@ static ZEND_OPCODE_HANDLER_RET ZEND_FASTCALL ZEND_CONCAT_SPEC_CONST_CONST_HANDLE
|
|||
}
|
||||
}
|
||||
if (IS_CONST != IS_CONST && IS_CONST != IS_CV &&
|
||||
!IS_INTERNED(op1_str) && GC_REFCOUNT(op1_str) == 1) {
|
||||
!ZSTR_IS_INTERNED(op1_str) && GC_REFCOUNT(op1_str) == 1) {
|
||||
size_t len = op1_str->len;
|
||||
|
||||
str = zend_string_realloc(op1_str, len + op2_str->len, 0);
|
||||
|
@ -6246,7 +6246,7 @@ num_index:
|
|||
offset = Z_REFVAL_P(offset);
|
||||
goto add_again;
|
||||
} else if (Z_TYPE_P(offset) == IS_NULL) {
|
||||
str = STR_EMPTY_ALLOC();
|
||||
str = ZSTR_EMPTY_ALLOC();
|
||||
goto str_index;
|
||||
} else if (Z_TYPE_P(offset) == IS_DOUBLE) {
|
||||
hval = zend_dval_to_lval(Z_DVAL_P(offset));
|
||||
|
@ -6259,7 +6259,7 @@ num_index:
|
|||
goto num_index;
|
||||
} else if (IS_CONST == IS_CV && Z_TYPE_P(offset) == IS_UNDEF) {
|
||||
GET_OP2_UNDEF_CV(offset, BP_VAR_R);
|
||||
str = STR_EMPTY_ALLOC();
|
||||
str = ZSTR_EMPTY_ALLOC();
|
||||
goto str_index;
|
||||
} else {
|
||||
zend_error(E_WARNING, "Illegal offset type");
|
||||
|
@ -6539,7 +6539,7 @@ num_index_prop:
|
|||
hval = zend_dval_to_lval(Z_DVAL_P(offset));
|
||||
goto num_index_prop;
|
||||
} else if (Z_TYPE_P(offset) == IS_NULL) {
|
||||
str = STR_EMPTY_ALLOC();
|
||||
str = ZSTR_EMPTY_ALLOC();
|
||||
goto str_index_prop;
|
||||
} else if (Z_TYPE_P(offset) == IS_FALSE) {
|
||||
hval = 0;
|
||||
|
@ -6552,7 +6552,7 @@ num_index_prop:
|
|||
goto num_index_prop;
|
||||
} else if (IS_CONST == IS_CV && Z_TYPE_P(offset) == IS_UNDEF) {
|
||||
GET_OP2_UNDEF_CV(offset, BP_VAR_R);
|
||||
str = STR_EMPTY_ALLOC();
|
||||
str = ZSTR_EMPTY_ALLOC();
|
||||
goto str_index_prop;
|
||||
} else {
|
||||
zend_error(E_WARNING, "Illegal offset type in isset or empty");
|
||||
|
@ -8097,7 +8097,7 @@ num_index:
|
|||
offset = Z_REFVAL_P(offset);
|
||||
goto add_again;
|
||||
} else if (Z_TYPE_P(offset) == IS_NULL) {
|
||||
str = STR_EMPTY_ALLOC();
|
||||
str = ZSTR_EMPTY_ALLOC();
|
||||
goto str_index;
|
||||
} else if (Z_TYPE_P(offset) == IS_DOUBLE) {
|
||||
hval = zend_dval_to_lval(Z_DVAL_P(offset));
|
||||
|
@ -8110,7 +8110,7 @@ num_index:
|
|||
goto num_index;
|
||||
} else if (IS_UNUSED == IS_CV && Z_TYPE_P(offset) == IS_UNDEF) {
|
||||
GET_OP2_UNDEF_CV(offset, BP_VAR_R);
|
||||
str = STR_EMPTY_ALLOC();
|
||||
str = ZSTR_EMPTY_ALLOC();
|
||||
goto str_index;
|
||||
} else {
|
||||
zend_error(E_WARNING, "Illegal offset type");
|
||||
|
@ -8760,7 +8760,7 @@ static ZEND_OPCODE_HANDLER_RET ZEND_FASTCALL ZEND_CONCAT_SPEC_CONST_CV_HANDLER(Z
|
|||
}
|
||||
}
|
||||
if (IS_CONST != IS_CONST && IS_CONST != IS_CV &&
|
||||
!IS_INTERNED(op1_str) && GC_REFCOUNT(op1_str) == 1) {
|
||||
!ZSTR_IS_INTERNED(op1_str) && GC_REFCOUNT(op1_str) == 1) {
|
||||
size_t len = op1_str->len;
|
||||
|
||||
str = zend_string_realloc(op1_str, len + op2_str->len, 0);
|
||||
|
@ -9981,7 +9981,7 @@ num_index:
|
|||
offset = Z_REFVAL_P(offset);
|
||||
goto add_again;
|
||||
} else if (Z_TYPE_P(offset) == IS_NULL) {
|
||||
str = STR_EMPTY_ALLOC();
|
||||
str = ZSTR_EMPTY_ALLOC();
|
||||
goto str_index;
|
||||
} else if (Z_TYPE_P(offset) == IS_DOUBLE) {
|
||||
hval = zend_dval_to_lval(Z_DVAL_P(offset));
|
||||
|
@ -9994,7 +9994,7 @@ num_index:
|
|||
goto num_index;
|
||||
} else if (IS_CV == IS_CV && Z_TYPE_P(offset) == IS_UNDEF) {
|
||||
GET_OP2_UNDEF_CV(offset, BP_VAR_R);
|
||||
str = STR_EMPTY_ALLOC();
|
||||
str = ZSTR_EMPTY_ALLOC();
|
||||
goto str_index;
|
||||
} else {
|
||||
zend_error(E_WARNING, "Illegal offset type");
|
||||
|
@ -10087,7 +10087,7 @@ num_index_prop:
|
|||
hval = zend_dval_to_lval(Z_DVAL_P(offset));
|
||||
goto num_index_prop;
|
||||
} else if (Z_TYPE_P(offset) == IS_NULL) {
|
||||
str = STR_EMPTY_ALLOC();
|
||||
str = ZSTR_EMPTY_ALLOC();
|
||||
goto str_index_prop;
|
||||
} else if (Z_TYPE_P(offset) == IS_FALSE) {
|
||||
hval = 0;
|
||||
|
@ -10100,7 +10100,7 @@ num_index_prop:
|
|||
goto num_index_prop;
|
||||
} else if (IS_CV == IS_CV && Z_TYPE_P(offset) == IS_UNDEF) {
|
||||
GET_OP2_UNDEF_CV(offset, BP_VAR_R);
|
||||
str = STR_EMPTY_ALLOC();
|
||||
str = ZSTR_EMPTY_ALLOC();
|
||||
goto str_index_prop;
|
||||
} else {
|
||||
zend_error(E_WARNING, "Illegal offset type in isset or empty");
|
||||
|
@ -10635,7 +10635,7 @@ static ZEND_OPCODE_HANDLER_RET ZEND_FASTCALL ZEND_CONCAT_SPEC_CONST_TMPVAR_HANDL
|
|||
}
|
||||
}
|
||||
if (IS_CONST != IS_CONST && IS_CONST != IS_CV &&
|
||||
!IS_INTERNED(op1_str) && GC_REFCOUNT(op1_str) == 1) {
|
||||
!ZSTR_IS_INTERNED(op1_str) && GC_REFCOUNT(op1_str) == 1) {
|
||||
size_t len = op1_str->len;
|
||||
|
||||
str = zend_string_realloc(op1_str, len + op2_str->len, 0);
|
||||
|
@ -11767,7 +11767,7 @@ num_index:
|
|||
offset = Z_REFVAL_P(offset);
|
||||
goto add_again;
|
||||
} else if (Z_TYPE_P(offset) == IS_NULL) {
|
||||
str = STR_EMPTY_ALLOC();
|
||||
str = ZSTR_EMPTY_ALLOC();
|
||||
goto str_index;
|
||||
} else if (Z_TYPE_P(offset) == IS_DOUBLE) {
|
||||
hval = zend_dval_to_lval(Z_DVAL_P(offset));
|
||||
|
@ -11780,7 +11780,7 @@ num_index:
|
|||
goto num_index;
|
||||
} else if ((IS_TMP_VAR|IS_VAR) == IS_CV && Z_TYPE_P(offset) == IS_UNDEF) {
|
||||
GET_OP2_UNDEF_CV(offset, BP_VAR_R);
|
||||
str = STR_EMPTY_ALLOC();
|
||||
str = ZSTR_EMPTY_ALLOC();
|
||||
goto str_index;
|
||||
} else {
|
||||
zend_error(E_WARNING, "Illegal offset type");
|
||||
|
@ -11873,7 +11873,7 @@ num_index_prop:
|
|||
hval = zend_dval_to_lval(Z_DVAL_P(offset));
|
||||
goto num_index_prop;
|
||||
} else if (Z_TYPE_P(offset) == IS_NULL) {
|
||||
str = STR_EMPTY_ALLOC();
|
||||
str = ZSTR_EMPTY_ALLOC();
|
||||
goto str_index_prop;
|
||||
} else if (Z_TYPE_P(offset) == IS_FALSE) {
|
||||
hval = 0;
|
||||
|
@ -11886,7 +11886,7 @@ num_index_prop:
|
|||
goto num_index_prop;
|
||||
} else if ((IS_TMP_VAR|IS_VAR) == IS_CV && Z_TYPE_P(offset) == IS_UNDEF) {
|
||||
GET_OP2_UNDEF_CV(offset, BP_VAR_R);
|
||||
str = STR_EMPTY_ALLOC();
|
||||
str = ZSTR_EMPTY_ALLOC();
|
||||
goto str_index_prop;
|
||||
} else {
|
||||
zend_error(E_WARNING, "Illegal offset type in isset or empty");
|
||||
|
@ -13244,7 +13244,7 @@ num_index:
|
|||
offset = Z_REFVAL_P(offset);
|
||||
goto add_again;
|
||||
} else if (Z_TYPE_P(offset) == IS_NULL) {
|
||||
str = STR_EMPTY_ALLOC();
|
||||
str = ZSTR_EMPTY_ALLOC();
|
||||
goto str_index;
|
||||
} else if (Z_TYPE_P(offset) == IS_DOUBLE) {
|
||||
hval = zend_dval_to_lval(Z_DVAL_P(offset));
|
||||
|
@ -13257,7 +13257,7 @@ num_index:
|
|||
goto num_index;
|
||||
} else if (IS_CONST == IS_CV && Z_TYPE_P(offset) == IS_UNDEF) {
|
||||
GET_OP2_UNDEF_CV(offset, BP_VAR_R);
|
||||
str = STR_EMPTY_ALLOC();
|
||||
str = ZSTR_EMPTY_ALLOC();
|
||||
goto str_index;
|
||||
} else {
|
||||
zend_error(E_WARNING, "Illegal offset type");
|
||||
|
@ -13976,7 +13976,7 @@ num_index:
|
|||
offset = Z_REFVAL_P(offset);
|
||||
goto add_again;
|
||||
} else if (Z_TYPE_P(offset) == IS_NULL) {
|
||||
str = STR_EMPTY_ALLOC();
|
||||
str = ZSTR_EMPTY_ALLOC();
|
||||
goto str_index;
|
||||
} else if (Z_TYPE_P(offset) == IS_DOUBLE) {
|
||||
hval = zend_dval_to_lval(Z_DVAL_P(offset));
|
||||
|
@ -13989,7 +13989,7 @@ num_index:
|
|||
goto num_index;
|
||||
} else if (IS_UNUSED == IS_CV && Z_TYPE_P(offset) == IS_UNDEF) {
|
||||
GET_OP2_UNDEF_CV(offset, BP_VAR_R);
|
||||
str = STR_EMPTY_ALLOC();
|
||||
str = ZSTR_EMPTY_ALLOC();
|
||||
goto str_index;
|
||||
} else {
|
||||
zend_error(E_WARNING, "Illegal offset type");
|
||||
|
@ -14530,7 +14530,7 @@ num_index:
|
|||
offset = Z_REFVAL_P(offset);
|
||||
goto add_again;
|
||||
} else if (Z_TYPE_P(offset) == IS_NULL) {
|
||||
str = STR_EMPTY_ALLOC();
|
||||
str = ZSTR_EMPTY_ALLOC();
|
||||
goto str_index;
|
||||
} else if (Z_TYPE_P(offset) == IS_DOUBLE) {
|
||||
hval = zend_dval_to_lval(Z_DVAL_P(offset));
|
||||
|
@ -14543,7 +14543,7 @@ num_index:
|
|||
goto num_index;
|
||||
} else if (IS_CV == IS_CV && Z_TYPE_P(offset) == IS_UNDEF) {
|
||||
GET_OP2_UNDEF_CV(offset, BP_VAR_R);
|
||||
str = STR_EMPTY_ALLOC();
|
||||
str = ZSTR_EMPTY_ALLOC();
|
||||
goto str_index;
|
||||
} else {
|
||||
zend_error(E_WARNING, "Illegal offset type");
|
||||
|
@ -15043,7 +15043,7 @@ num_index:
|
|||
offset = Z_REFVAL_P(offset);
|
||||
goto add_again;
|
||||
} else if (Z_TYPE_P(offset) == IS_NULL) {
|
||||
str = STR_EMPTY_ALLOC();
|
||||
str = ZSTR_EMPTY_ALLOC();
|
||||
goto str_index;
|
||||
} else if (Z_TYPE_P(offset) == IS_DOUBLE) {
|
||||
hval = zend_dval_to_lval(Z_DVAL_P(offset));
|
||||
|
@ -15056,7 +15056,7 @@ num_index:
|
|||
goto num_index;
|
||||
} else if ((IS_TMP_VAR|IS_VAR) == IS_CV && Z_TYPE_P(offset) == IS_UNDEF) {
|
||||
GET_OP2_UNDEF_CV(offset, BP_VAR_R);
|
||||
str = STR_EMPTY_ALLOC();
|
||||
str = ZSTR_EMPTY_ALLOC();
|
||||
goto str_index;
|
||||
} else {
|
||||
zend_error(E_WARNING, "Illegal offset type");
|
||||
|
@ -18141,7 +18141,7 @@ num_index:
|
|||
offset = Z_REFVAL_P(offset);
|
||||
goto add_again;
|
||||
} else if (Z_TYPE_P(offset) == IS_NULL) {
|
||||
str = STR_EMPTY_ALLOC();
|
||||
str = ZSTR_EMPTY_ALLOC();
|
||||
goto str_index;
|
||||
} else if (Z_TYPE_P(offset) == IS_DOUBLE) {
|
||||
hval = zend_dval_to_lval(Z_DVAL_P(offset));
|
||||
|
@ -18154,7 +18154,7 @@ num_index:
|
|||
goto num_index;
|
||||
} else if (IS_CONST == IS_CV && Z_TYPE_P(offset) == IS_UNDEF) {
|
||||
GET_OP2_UNDEF_CV(offset, BP_VAR_R);
|
||||
str = STR_EMPTY_ALLOC();
|
||||
str = ZSTR_EMPTY_ALLOC();
|
||||
goto str_index;
|
||||
} else {
|
||||
zend_error(E_WARNING, "Illegal offset type");
|
||||
|
@ -18254,7 +18254,7 @@ num_index_dim:
|
|||
hval = zend_dval_to_lval(Z_DVAL_P(offset));
|
||||
goto num_index_dim;
|
||||
} else if (Z_TYPE_P(offset) == IS_NULL) {
|
||||
key = STR_EMPTY_ALLOC();
|
||||
key = ZSTR_EMPTY_ALLOC();
|
||||
goto str_index_dim;
|
||||
} else if (Z_TYPE_P(offset) == IS_FALSE) {
|
||||
hval = 0;
|
||||
|
@ -18267,7 +18267,7 @@ num_index_dim:
|
|||
goto num_index_dim;
|
||||
} else if (IS_CONST == IS_CV && Z_TYPE_P(offset) == IS_UNDEF) {
|
||||
GET_OP2_UNDEF_CV(offset, BP_VAR_R);
|
||||
key = STR_EMPTY_ALLOC();
|
||||
key = ZSTR_EMPTY_ALLOC();
|
||||
goto str_index_dim;
|
||||
} else {
|
||||
zend_error(E_WARNING, "Illegal offset type in unset");
|
||||
|
@ -19725,7 +19725,7 @@ num_index:
|
|||
offset = Z_REFVAL_P(offset);
|
||||
goto add_again;
|
||||
} else if (Z_TYPE_P(offset) == IS_NULL) {
|
||||
str = STR_EMPTY_ALLOC();
|
||||
str = ZSTR_EMPTY_ALLOC();
|
||||
goto str_index;
|
||||
} else if (Z_TYPE_P(offset) == IS_DOUBLE) {
|
||||
hval = zend_dval_to_lval(Z_DVAL_P(offset));
|
||||
|
@ -19738,7 +19738,7 @@ num_index:
|
|||
goto num_index;
|
||||
} else if (IS_UNUSED == IS_CV && Z_TYPE_P(offset) == IS_UNDEF) {
|
||||
GET_OP2_UNDEF_CV(offset, BP_VAR_R);
|
||||
str = STR_EMPTY_ALLOC();
|
||||
str = ZSTR_EMPTY_ALLOC();
|
||||
goto str_index;
|
||||
} else {
|
||||
zend_error(E_WARNING, "Illegal offset type");
|
||||
|
@ -21300,7 +21300,7 @@ num_index:
|
|||
offset = Z_REFVAL_P(offset);
|
||||
goto add_again;
|
||||
} else if (Z_TYPE_P(offset) == IS_NULL) {
|
||||
str = STR_EMPTY_ALLOC();
|
||||
str = ZSTR_EMPTY_ALLOC();
|
||||
goto str_index;
|
||||
} else if (Z_TYPE_P(offset) == IS_DOUBLE) {
|
||||
hval = zend_dval_to_lval(Z_DVAL_P(offset));
|
||||
|
@ -21313,7 +21313,7 @@ num_index:
|
|||
goto num_index;
|
||||
} else if (IS_CV == IS_CV && Z_TYPE_P(offset) == IS_UNDEF) {
|
||||
GET_OP2_UNDEF_CV(offset, BP_VAR_R);
|
||||
str = STR_EMPTY_ALLOC();
|
||||
str = ZSTR_EMPTY_ALLOC();
|
||||
goto str_index;
|
||||
} else {
|
||||
zend_error(E_WARNING, "Illegal offset type");
|
||||
|
@ -21413,7 +21413,7 @@ num_index_dim:
|
|||
hval = zend_dval_to_lval(Z_DVAL_P(offset));
|
||||
goto num_index_dim;
|
||||
} else if (Z_TYPE_P(offset) == IS_NULL) {
|
||||
key = STR_EMPTY_ALLOC();
|
||||
key = ZSTR_EMPTY_ALLOC();
|
||||
goto str_index_dim;
|
||||
} else if (Z_TYPE_P(offset) == IS_FALSE) {
|
||||
hval = 0;
|
||||
|
@ -21426,7 +21426,7 @@ num_index_dim:
|
|||
goto num_index_dim;
|
||||
} else if (IS_CV == IS_CV && Z_TYPE_P(offset) == IS_UNDEF) {
|
||||
GET_OP2_UNDEF_CV(offset, BP_VAR_R);
|
||||
key = STR_EMPTY_ALLOC();
|
||||
key = ZSTR_EMPTY_ALLOC();
|
||||
goto str_index_dim;
|
||||
} else {
|
||||
zend_error(E_WARNING, "Illegal offset type in unset");
|
||||
|
@ -22879,7 +22879,7 @@ num_index:
|
|||
offset = Z_REFVAL_P(offset);
|
||||
goto add_again;
|
||||
} else if (Z_TYPE_P(offset) == IS_NULL) {
|
||||
str = STR_EMPTY_ALLOC();
|
||||
str = ZSTR_EMPTY_ALLOC();
|
||||
goto str_index;
|
||||
} else if (Z_TYPE_P(offset) == IS_DOUBLE) {
|
||||
hval = zend_dval_to_lval(Z_DVAL_P(offset));
|
||||
|
@ -22892,7 +22892,7 @@ num_index:
|
|||
goto num_index;
|
||||
} else if ((IS_TMP_VAR|IS_VAR) == IS_CV && Z_TYPE_P(offset) == IS_UNDEF) {
|
||||
GET_OP2_UNDEF_CV(offset, BP_VAR_R);
|
||||
str = STR_EMPTY_ALLOC();
|
||||
str = ZSTR_EMPTY_ALLOC();
|
||||
goto str_index;
|
||||
} else {
|
||||
zend_error(E_WARNING, "Illegal offset type");
|
||||
|
@ -22992,7 +22992,7 @@ num_index_dim:
|
|||
hval = zend_dval_to_lval(Z_DVAL_P(offset));
|
||||
goto num_index_dim;
|
||||
} else if (Z_TYPE_P(offset) == IS_NULL) {
|
||||
key = STR_EMPTY_ALLOC();
|
||||
key = ZSTR_EMPTY_ALLOC();
|
||||
goto str_index_dim;
|
||||
} else if (Z_TYPE_P(offset) == IS_FALSE) {
|
||||
hval = 0;
|
||||
|
@ -23005,7 +23005,7 @@ num_index_dim:
|
|||
goto num_index_dim;
|
||||
} else if ((IS_TMP_VAR|IS_VAR) == IS_CV && Z_TYPE_P(offset) == IS_UNDEF) {
|
||||
GET_OP2_UNDEF_CV(offset, BP_VAR_R);
|
||||
key = STR_EMPTY_ALLOC();
|
||||
key = ZSTR_EMPTY_ALLOC();
|
||||
goto str_index_dim;
|
||||
} else {
|
||||
zend_error(E_WARNING, "Illegal offset type in unset");
|
||||
|
@ -24383,7 +24383,7 @@ num_index_dim:
|
|||
hval = zend_dval_to_lval(Z_DVAL_P(offset));
|
||||
goto num_index_dim;
|
||||
} else if (Z_TYPE_P(offset) == IS_NULL) {
|
||||
key = STR_EMPTY_ALLOC();
|
||||
key = ZSTR_EMPTY_ALLOC();
|
||||
goto str_index_dim;
|
||||
} else if (Z_TYPE_P(offset) == IS_FALSE) {
|
||||
hval = 0;
|
||||
|
@ -24396,7 +24396,7 @@ num_index_dim:
|
|||
goto num_index_dim;
|
||||
} else if (IS_CONST == IS_CV && Z_TYPE_P(offset) == IS_UNDEF) {
|
||||
GET_OP2_UNDEF_CV(offset, BP_VAR_R);
|
||||
key = STR_EMPTY_ALLOC();
|
||||
key = ZSTR_EMPTY_ALLOC();
|
||||
goto str_index_dim;
|
||||
} else {
|
||||
zend_error(E_WARNING, "Illegal offset type in unset");
|
||||
|
@ -24519,7 +24519,7 @@ num_index_prop:
|
|||
hval = zend_dval_to_lval(Z_DVAL_P(offset));
|
||||
goto num_index_prop;
|
||||
} else if (Z_TYPE_P(offset) == IS_NULL) {
|
||||
str = STR_EMPTY_ALLOC();
|
||||
str = ZSTR_EMPTY_ALLOC();
|
||||
goto str_index_prop;
|
||||
} else if (Z_TYPE_P(offset) == IS_FALSE) {
|
||||
hval = 0;
|
||||
|
@ -24532,7 +24532,7 @@ num_index_prop:
|
|||
goto num_index_prop;
|
||||
} else if (IS_CONST == IS_CV && Z_TYPE_P(offset) == IS_UNDEF) {
|
||||
GET_OP2_UNDEF_CV(offset, BP_VAR_R);
|
||||
str = STR_EMPTY_ALLOC();
|
||||
str = ZSTR_EMPTY_ALLOC();
|
||||
goto str_index_prop;
|
||||
} else {
|
||||
zend_error(E_WARNING, "Illegal offset type in isset or empty");
|
||||
|
@ -26670,7 +26670,7 @@ num_index_dim:
|
|||
hval = zend_dval_to_lval(Z_DVAL_P(offset));
|
||||
goto num_index_dim;
|
||||
} else if (Z_TYPE_P(offset) == IS_NULL) {
|
||||
key = STR_EMPTY_ALLOC();
|
||||
key = ZSTR_EMPTY_ALLOC();
|
||||
goto str_index_dim;
|
||||
} else if (Z_TYPE_P(offset) == IS_FALSE) {
|
||||
hval = 0;
|
||||
|
@ -26683,7 +26683,7 @@ num_index_dim:
|
|||
goto num_index_dim;
|
||||
} else if (IS_CV == IS_CV && Z_TYPE_P(offset) == IS_UNDEF) {
|
||||
GET_OP2_UNDEF_CV(offset, BP_VAR_R);
|
||||
key = STR_EMPTY_ALLOC();
|
||||
key = ZSTR_EMPTY_ALLOC();
|
||||
goto str_index_dim;
|
||||
} else {
|
||||
zend_error(E_WARNING, "Illegal offset type in unset");
|
||||
|
@ -26806,7 +26806,7 @@ num_index_prop:
|
|||
hval = zend_dval_to_lval(Z_DVAL_P(offset));
|
||||
goto num_index_prop;
|
||||
} else if (Z_TYPE_P(offset) == IS_NULL) {
|
||||
str = STR_EMPTY_ALLOC();
|
||||
str = ZSTR_EMPTY_ALLOC();
|
||||
goto str_index_prop;
|
||||
} else if (Z_TYPE_P(offset) == IS_FALSE) {
|
||||
hval = 0;
|
||||
|
@ -26819,7 +26819,7 @@ num_index_prop:
|
|||
goto num_index_prop;
|
||||
} else if (IS_CV == IS_CV && Z_TYPE_P(offset) == IS_UNDEF) {
|
||||
GET_OP2_UNDEF_CV(offset, BP_VAR_R);
|
||||
str = STR_EMPTY_ALLOC();
|
||||
str = ZSTR_EMPTY_ALLOC();
|
||||
goto str_index_prop;
|
||||
} else {
|
||||
zend_error(E_WARNING, "Illegal offset type in isset or empty");
|
||||
|
@ -28164,7 +28164,7 @@ num_index_dim:
|
|||
hval = zend_dval_to_lval(Z_DVAL_P(offset));
|
||||
goto num_index_dim;
|
||||
} else if (Z_TYPE_P(offset) == IS_NULL) {
|
||||
key = STR_EMPTY_ALLOC();
|
||||
key = ZSTR_EMPTY_ALLOC();
|
||||
goto str_index_dim;
|
||||
} else if (Z_TYPE_P(offset) == IS_FALSE) {
|
||||
hval = 0;
|
||||
|
@ -28177,7 +28177,7 @@ num_index_dim:
|
|||
goto num_index_dim;
|
||||
} else if ((IS_TMP_VAR|IS_VAR) == IS_CV && Z_TYPE_P(offset) == IS_UNDEF) {
|
||||
GET_OP2_UNDEF_CV(offset, BP_VAR_R);
|
||||
key = STR_EMPTY_ALLOC();
|
||||
key = ZSTR_EMPTY_ALLOC();
|
||||
goto str_index_dim;
|
||||
} else {
|
||||
zend_error(E_WARNING, "Illegal offset type in unset");
|
||||
|
@ -28302,7 +28302,7 @@ num_index_prop:
|
|||
hval = zend_dval_to_lval(Z_DVAL_P(offset));
|
||||
goto num_index_prop;
|
||||
} else if (Z_TYPE_P(offset) == IS_NULL) {
|
||||
str = STR_EMPTY_ALLOC();
|
||||
str = ZSTR_EMPTY_ALLOC();
|
||||
goto str_index_prop;
|
||||
} else if (Z_TYPE_P(offset) == IS_FALSE) {
|
||||
hval = 0;
|
||||
|
@ -28315,7 +28315,7 @@ num_index_prop:
|
|||
goto num_index_prop;
|
||||
} else if ((IS_TMP_VAR|IS_VAR) == IS_CV && Z_TYPE_P(offset) == IS_UNDEF) {
|
||||
GET_OP2_UNDEF_CV(offset, BP_VAR_R);
|
||||
str = STR_EMPTY_ALLOC();
|
||||
str = ZSTR_EMPTY_ALLOC();
|
||||
goto str_index_prop;
|
||||
} else {
|
||||
zend_error(E_WARNING, "Illegal offset type in isset or empty");
|
||||
|
@ -30455,7 +30455,7 @@ static ZEND_OPCODE_HANDLER_RET ZEND_FASTCALL ZEND_CONCAT_SPEC_CV_CONST_HANDLER(Z
|
|||
}
|
||||
}
|
||||
if (IS_CV != IS_CONST && IS_CV != IS_CV &&
|
||||
!IS_INTERNED(op1_str) && GC_REFCOUNT(op1_str) == 1) {
|
||||
!ZSTR_IS_INTERNED(op1_str) && GC_REFCOUNT(op1_str) == 1) {
|
||||
size_t len = op1_str->len;
|
||||
|
||||
str = zend_string_realloc(op1_str, len + op2_str->len, 0);
|
||||
|
@ -32558,7 +32558,7 @@ num_index:
|
|||
offset = Z_REFVAL_P(offset);
|
||||
goto add_again;
|
||||
} else if (Z_TYPE_P(offset) == IS_NULL) {
|
||||
str = STR_EMPTY_ALLOC();
|
||||
str = ZSTR_EMPTY_ALLOC();
|
||||
goto str_index;
|
||||
} else if (Z_TYPE_P(offset) == IS_DOUBLE) {
|
||||
hval = zend_dval_to_lval(Z_DVAL_P(offset));
|
||||
|
@ -32571,7 +32571,7 @@ num_index:
|
|||
goto num_index;
|
||||
} else if (IS_CONST == IS_CV && Z_TYPE_P(offset) == IS_UNDEF) {
|
||||
GET_OP2_UNDEF_CV(offset, BP_VAR_R);
|
||||
str = STR_EMPTY_ALLOC();
|
||||
str = ZSTR_EMPTY_ALLOC();
|
||||
goto str_index;
|
||||
} else {
|
||||
zend_error(E_WARNING, "Illegal offset type");
|
||||
|
@ -32753,7 +32753,7 @@ num_index_dim:
|
|||
hval = zend_dval_to_lval(Z_DVAL_P(offset));
|
||||
goto num_index_dim;
|
||||
} else if (Z_TYPE_P(offset) == IS_NULL) {
|
||||
key = STR_EMPTY_ALLOC();
|
||||
key = ZSTR_EMPTY_ALLOC();
|
||||
goto str_index_dim;
|
||||
} else if (Z_TYPE_P(offset) == IS_FALSE) {
|
||||
hval = 0;
|
||||
|
@ -32766,7 +32766,7 @@ num_index_dim:
|
|||
goto num_index_dim;
|
||||
} else if (IS_CONST == IS_CV && Z_TYPE_P(offset) == IS_UNDEF) {
|
||||
GET_OP2_UNDEF_CV(offset, BP_VAR_R);
|
||||
key = STR_EMPTY_ALLOC();
|
||||
key = ZSTR_EMPTY_ALLOC();
|
||||
goto str_index_dim;
|
||||
} else {
|
||||
zend_error(E_WARNING, "Illegal offset type in unset");
|
||||
|
@ -32994,7 +32994,7 @@ num_index_prop:
|
|||
hval = zend_dval_to_lval(Z_DVAL_P(offset));
|
||||
goto num_index_prop;
|
||||
} else if (Z_TYPE_P(offset) == IS_NULL) {
|
||||
str = STR_EMPTY_ALLOC();
|
||||
str = ZSTR_EMPTY_ALLOC();
|
||||
goto str_index_prop;
|
||||
} else if (Z_TYPE_P(offset) == IS_FALSE) {
|
||||
hval = 0;
|
||||
|
@ -33007,7 +33007,7 @@ num_index_prop:
|
|||
goto num_index_prop;
|
||||
} else if (IS_CONST == IS_CV && Z_TYPE_P(offset) == IS_UNDEF) {
|
||||
GET_OP2_UNDEF_CV(offset, BP_VAR_R);
|
||||
str = STR_EMPTY_ALLOC();
|
||||
str = ZSTR_EMPTY_ALLOC();
|
||||
goto str_index_prop;
|
||||
} else {
|
||||
zend_error(E_WARNING, "Illegal offset type in isset or empty");
|
||||
|
@ -35129,7 +35129,7 @@ num_index:
|
|||
offset = Z_REFVAL_P(offset);
|
||||
goto add_again;
|
||||
} else if (Z_TYPE_P(offset) == IS_NULL) {
|
||||
str = STR_EMPTY_ALLOC();
|
||||
str = ZSTR_EMPTY_ALLOC();
|
||||
goto str_index;
|
||||
} else if (Z_TYPE_P(offset) == IS_DOUBLE) {
|
||||
hval = zend_dval_to_lval(Z_DVAL_P(offset));
|
||||
|
@ -35142,7 +35142,7 @@ num_index:
|
|||
goto num_index;
|
||||
} else if (IS_UNUSED == IS_CV && Z_TYPE_P(offset) == IS_UNDEF) {
|
||||
GET_OP2_UNDEF_CV(offset, BP_VAR_R);
|
||||
str = STR_EMPTY_ALLOC();
|
||||
str = ZSTR_EMPTY_ALLOC();
|
||||
goto str_index;
|
||||
} else {
|
||||
zend_error(E_WARNING, "Illegal offset type");
|
||||
|
@ -35769,7 +35769,7 @@ static ZEND_OPCODE_HANDLER_RET ZEND_FASTCALL ZEND_CONCAT_SPEC_CV_CV_HANDLER(ZEND
|
|||
}
|
||||
}
|
||||
if (IS_CV != IS_CONST && IS_CV != IS_CV &&
|
||||
!IS_INTERNED(op1_str) && GC_REFCOUNT(op1_str) == 1) {
|
||||
!ZSTR_IS_INTERNED(op1_str) && GC_REFCOUNT(op1_str) == 1) {
|
||||
size_t len = op1_str->len;
|
||||
|
||||
str = zend_string_realloc(op1_str, len + op2_str->len, 0);
|
||||
|
@ -37700,7 +37700,7 @@ num_index:
|
|||
offset = Z_REFVAL_P(offset);
|
||||
goto add_again;
|
||||
} else if (Z_TYPE_P(offset) == IS_NULL) {
|
||||
str = STR_EMPTY_ALLOC();
|
||||
str = ZSTR_EMPTY_ALLOC();
|
||||
goto str_index;
|
||||
} else if (Z_TYPE_P(offset) == IS_DOUBLE) {
|
||||
hval = zend_dval_to_lval(Z_DVAL_P(offset));
|
||||
|
@ -37713,7 +37713,7 @@ num_index:
|
|||
goto num_index;
|
||||
} else if (IS_CV == IS_CV && Z_TYPE_P(offset) == IS_UNDEF) {
|
||||
GET_OP2_UNDEF_CV(offset, BP_VAR_R);
|
||||
str = STR_EMPTY_ALLOC();
|
||||
str = ZSTR_EMPTY_ALLOC();
|
||||
goto str_index;
|
||||
} else {
|
||||
zend_error(E_WARNING, "Illegal offset type");
|
||||
|
@ -37813,7 +37813,7 @@ num_index_dim:
|
|||
hval = zend_dval_to_lval(Z_DVAL_P(offset));
|
||||
goto num_index_dim;
|
||||
} else if (Z_TYPE_P(offset) == IS_NULL) {
|
||||
key = STR_EMPTY_ALLOC();
|
||||
key = ZSTR_EMPTY_ALLOC();
|
||||
goto str_index_dim;
|
||||
} else if (Z_TYPE_P(offset) == IS_FALSE) {
|
||||
hval = 0;
|
||||
|
@ -37826,7 +37826,7 @@ num_index_dim:
|
|||
goto num_index_dim;
|
||||
} else if (IS_CV == IS_CV && Z_TYPE_P(offset) == IS_UNDEF) {
|
||||
GET_OP2_UNDEF_CV(offset, BP_VAR_R);
|
||||
key = STR_EMPTY_ALLOC();
|
||||
key = ZSTR_EMPTY_ALLOC();
|
||||
goto str_index_dim;
|
||||
} else {
|
||||
zend_error(E_WARNING, "Illegal offset type in unset");
|
||||
|
@ -37949,7 +37949,7 @@ num_index_prop:
|
|||
hval = zend_dval_to_lval(Z_DVAL_P(offset));
|
||||
goto num_index_prop;
|
||||
} else if (Z_TYPE_P(offset) == IS_NULL) {
|
||||
str = STR_EMPTY_ALLOC();
|
||||
str = ZSTR_EMPTY_ALLOC();
|
||||
goto str_index_prop;
|
||||
} else if (Z_TYPE_P(offset) == IS_FALSE) {
|
||||
hval = 0;
|
||||
|
@ -37962,7 +37962,7 @@ num_index_prop:
|
|||
goto num_index_prop;
|
||||
} else if (IS_CV == IS_CV && Z_TYPE_P(offset) == IS_UNDEF) {
|
||||
GET_OP2_UNDEF_CV(offset, BP_VAR_R);
|
||||
str = STR_EMPTY_ALLOC();
|
||||
str = ZSTR_EMPTY_ALLOC();
|
||||
goto str_index_prop;
|
||||
} else {
|
||||
zend_error(E_WARNING, "Illegal offset type in isset or empty");
|
||||
|
@ -38502,7 +38502,7 @@ static ZEND_OPCODE_HANDLER_RET ZEND_FASTCALL ZEND_CONCAT_SPEC_CV_TMPVAR_HANDLER(
|
|||
}
|
||||
}
|
||||
if (IS_CV != IS_CONST && IS_CV != IS_CV &&
|
||||
!IS_INTERNED(op1_str) && GC_REFCOUNT(op1_str) == 1) {
|
||||
!ZSTR_IS_INTERNED(op1_str) && GC_REFCOUNT(op1_str) == 1) {
|
||||
size_t len = op1_str->len;
|
||||
|
||||
str = zend_string_realloc(op1_str, len + op2_str->len, 0);
|
||||
|
@ -40309,7 +40309,7 @@ num_index:
|
|||
offset = Z_REFVAL_P(offset);
|
||||
goto add_again;
|
||||
} else if (Z_TYPE_P(offset) == IS_NULL) {
|
||||
str = STR_EMPTY_ALLOC();
|
||||
str = ZSTR_EMPTY_ALLOC();
|
||||
goto str_index;
|
||||
} else if (Z_TYPE_P(offset) == IS_DOUBLE) {
|
||||
hval = zend_dval_to_lval(Z_DVAL_P(offset));
|
||||
|
@ -40322,7 +40322,7 @@ num_index:
|
|||
goto num_index;
|
||||
} else if ((IS_TMP_VAR|IS_VAR) == IS_CV && Z_TYPE_P(offset) == IS_UNDEF) {
|
||||
GET_OP2_UNDEF_CV(offset, BP_VAR_R);
|
||||
str = STR_EMPTY_ALLOC();
|
||||
str = ZSTR_EMPTY_ALLOC();
|
||||
goto str_index;
|
||||
} else {
|
||||
zend_error(E_WARNING, "Illegal offset type");
|
||||
|
@ -40422,7 +40422,7 @@ num_index_dim:
|
|||
hval = zend_dval_to_lval(Z_DVAL_P(offset));
|
||||
goto num_index_dim;
|
||||
} else if (Z_TYPE_P(offset) == IS_NULL) {
|
||||
key = STR_EMPTY_ALLOC();
|
||||
key = ZSTR_EMPTY_ALLOC();
|
||||
goto str_index_dim;
|
||||
} else if (Z_TYPE_P(offset) == IS_FALSE) {
|
||||
hval = 0;
|
||||
|
@ -40435,7 +40435,7 @@ num_index_dim:
|
|||
goto num_index_dim;
|
||||
} else if ((IS_TMP_VAR|IS_VAR) == IS_CV && Z_TYPE_P(offset) == IS_UNDEF) {
|
||||
GET_OP2_UNDEF_CV(offset, BP_VAR_R);
|
||||
key = STR_EMPTY_ALLOC();
|
||||
key = ZSTR_EMPTY_ALLOC();
|
||||
goto str_index_dim;
|
||||
} else {
|
||||
zend_error(E_WARNING, "Illegal offset type in unset");
|
||||
|
@ -40560,7 +40560,7 @@ num_index_prop:
|
|||
hval = zend_dval_to_lval(Z_DVAL_P(offset));
|
||||
goto num_index_prop;
|
||||
} else if (Z_TYPE_P(offset) == IS_NULL) {
|
||||
str = STR_EMPTY_ALLOC();
|
||||
str = ZSTR_EMPTY_ALLOC();
|
||||
goto str_index_prop;
|
||||
} else if (Z_TYPE_P(offset) == IS_FALSE) {
|
||||
hval = 0;
|
||||
|
@ -40573,7 +40573,7 @@ num_index_prop:
|
|||
goto num_index_prop;
|
||||
} else if ((IS_TMP_VAR|IS_VAR) == IS_CV && Z_TYPE_P(offset) == IS_UNDEF) {
|
||||
GET_OP2_UNDEF_CV(offset, BP_VAR_R);
|
||||
str = STR_EMPTY_ALLOC();
|
||||
str = ZSTR_EMPTY_ALLOC();
|
||||
goto str_index_prop;
|
||||
} else {
|
||||
zend_error(E_WARNING, "Illegal offset type in isset or empty");
|
||||
|
@ -41577,7 +41577,7 @@ static ZEND_OPCODE_HANDLER_RET ZEND_FASTCALL ZEND_CONCAT_SPEC_TMPVAR_CONST_HANDL
|
|||
}
|
||||
}
|
||||
if ((IS_TMP_VAR|IS_VAR) != IS_CONST && (IS_TMP_VAR|IS_VAR) != IS_CV &&
|
||||
!IS_INTERNED(op1_str) && GC_REFCOUNT(op1_str) == 1) {
|
||||
!ZSTR_IS_INTERNED(op1_str) && GC_REFCOUNT(op1_str) == 1) {
|
||||
size_t len = op1_str->len;
|
||||
|
||||
str = zend_string_realloc(op1_str, len + op2_str->len, 0);
|
||||
|
@ -42754,7 +42754,7 @@ num_index_prop:
|
|||
hval = zend_dval_to_lval(Z_DVAL_P(offset));
|
||||
goto num_index_prop;
|
||||
} else if (Z_TYPE_P(offset) == IS_NULL) {
|
||||
str = STR_EMPTY_ALLOC();
|
||||
str = ZSTR_EMPTY_ALLOC();
|
||||
goto str_index_prop;
|
||||
} else if (Z_TYPE_P(offset) == IS_FALSE) {
|
||||
hval = 0;
|
||||
|
@ -42767,7 +42767,7 @@ num_index_prop:
|
|||
goto num_index_prop;
|
||||
} else if (IS_CONST == IS_CV && Z_TYPE_P(offset) == IS_UNDEF) {
|
||||
GET_OP2_UNDEF_CV(offset, BP_VAR_R);
|
||||
str = STR_EMPTY_ALLOC();
|
||||
str = ZSTR_EMPTY_ALLOC();
|
||||
goto str_index_prop;
|
||||
} else {
|
||||
zend_error(E_WARNING, "Illegal offset type in isset or empty");
|
||||
|
@ -44007,7 +44007,7 @@ static ZEND_OPCODE_HANDLER_RET ZEND_FASTCALL ZEND_CONCAT_SPEC_TMPVAR_CV_HANDLER(
|
|||
}
|
||||
}
|
||||
if ((IS_TMP_VAR|IS_VAR) != IS_CONST && (IS_TMP_VAR|IS_VAR) != IS_CV &&
|
||||
!IS_INTERNED(op1_str) && GC_REFCOUNT(op1_str) == 1) {
|
||||
!ZSTR_IS_INTERNED(op1_str) && GC_REFCOUNT(op1_str) == 1) {
|
||||
size_t len = op1_str->len;
|
||||
|
||||
str = zend_string_realloc(op1_str, len + op2_str->len, 0);
|
||||
|
@ -44763,7 +44763,7 @@ num_index_prop:
|
|||
hval = zend_dval_to_lval(Z_DVAL_P(offset));
|
||||
goto num_index_prop;
|
||||
} else if (Z_TYPE_P(offset) == IS_NULL) {
|
||||
str = STR_EMPTY_ALLOC();
|
||||
str = ZSTR_EMPTY_ALLOC();
|
||||
goto str_index_prop;
|
||||
} else if (Z_TYPE_P(offset) == IS_FALSE) {
|
||||
hval = 0;
|
||||
|
@ -44776,7 +44776,7 @@ num_index_prop:
|
|||
goto num_index_prop;
|
||||
} else if (IS_CV == IS_CV && Z_TYPE_P(offset) == IS_UNDEF) {
|
||||
GET_OP2_UNDEF_CV(offset, BP_VAR_R);
|
||||
str = STR_EMPTY_ALLOC();
|
||||
str = ZSTR_EMPTY_ALLOC();
|
||||
goto str_index_prop;
|
||||
} else {
|
||||
zend_error(E_WARNING, "Illegal offset type in isset or empty");
|
||||
|
@ -45170,7 +45170,7 @@ static ZEND_OPCODE_HANDLER_RET ZEND_FASTCALL ZEND_CONCAT_SPEC_TMPVAR_TMPVAR_HAND
|
|||
}
|
||||
}
|
||||
if ((IS_TMP_VAR|IS_VAR) != IS_CONST && (IS_TMP_VAR|IS_VAR) != IS_CV &&
|
||||
!IS_INTERNED(op1_str) && GC_REFCOUNT(op1_str) == 1) {
|
||||
!ZSTR_IS_INTERNED(op1_str) && GC_REFCOUNT(op1_str) == 1) {
|
||||
size_t len = op1_str->len;
|
||||
|
||||
str = zend_string_realloc(op1_str, len + op2_str->len, 0);
|
||||
|
@ -45928,7 +45928,7 @@ num_index_prop:
|
|||
hval = zend_dval_to_lval(Z_DVAL_P(offset));
|
||||
goto num_index_prop;
|
||||
} else if (Z_TYPE_P(offset) == IS_NULL) {
|
||||
str = STR_EMPTY_ALLOC();
|
||||
str = ZSTR_EMPTY_ALLOC();
|
||||
goto str_index_prop;
|
||||
} else if (Z_TYPE_P(offset) == IS_FALSE) {
|
||||
hval = 0;
|
||||
|
@ -45941,7 +45941,7 @@ num_index_prop:
|
|||
goto num_index_prop;
|
||||
} else if ((IS_TMP_VAR|IS_VAR) == IS_CV && Z_TYPE_P(offset) == IS_UNDEF) {
|
||||
GET_OP2_UNDEF_CV(offset, BP_VAR_R);
|
||||
str = STR_EMPTY_ALLOC();
|
||||
str = ZSTR_EMPTY_ALLOC();
|
||||
goto str_index_prop;
|
||||
} else {
|
||||
zend_error(E_WARNING, "Illegal offset type in isset or empty");
|
||||
|
|
|
@ -157,7 +157,7 @@ static void _php_curl_close(zend_resource *rsrc);
|
|||
#define CAAL(s, v) add_assoc_long_ex(return_value, s, sizeof(s) - 1, (zend_long) v);
|
||||
#define CAAD(s, v) add_assoc_double_ex(return_value, s, sizeof(s) - 1, (double) v);
|
||||
#define CAAS(s, v) add_assoc_string_ex(return_value, s, sizeof(s) - 1, (char *) (v ? v : ""));
|
||||
#define CAASTR(s, v) add_assoc_str_ex(return_value, s, sizeof(s) - 1, v ? v : STR_EMPTY_ALLOC());
|
||||
#define CAASTR(s, v) add_assoc_str_ex(return_value, s, sizeof(s) - 1, v ? v : ZSTR_EMPTY_ALLOC());
|
||||
#define CAAZ(s, v) add_assoc_zval_ex(return_value, s, sizeof(s) -1 , (zval *) v);
|
||||
|
||||
#if defined(PHP_WIN32) || defined(__GNUC__)
|
||||
|
|
|
@ -1079,7 +1079,7 @@ static zend_string *date_format(char *format, size_t format_len, timelib_time *t
|
|||
int weekYearSet = 0;
|
||||
|
||||
if (!format_len) {
|
||||
return STR_EMPTY_ALLOC();
|
||||
return ZSTR_EMPTY_ALLOC();
|
||||
}
|
||||
|
||||
if (localtime) {
|
||||
|
@ -4212,7 +4212,7 @@ static zend_string *date_interval_format(char *format, size_t format_len, timeli
|
|||
char buffer[33];
|
||||
|
||||
if (!format_len) {
|
||||
return STR_EMPTY_ALLOC();
|
||||
return ZSTR_EMPTY_ALLOC();
|
||||
}
|
||||
|
||||
for (i = 0; i < format_len; i++) {
|
||||
|
|
|
@ -249,7 +249,7 @@ U_CFUNC zend_function *IntlPartsIterator_get_method(zend_object **object_ptr, ze
|
|||
ALLOCA_FLAG(use_heap);
|
||||
|
||||
if (key == NULL) {
|
||||
STR_ALLOCA_ALLOC(lc_method_name, method->len, use_heap);
|
||||
ZSTR_ALLOCA_ALLOC(lc_method_name, method->len, use_heap);
|
||||
zend_str_tolower_copy(lc_method_name->val, method->val, method->len);
|
||||
} else {
|
||||
lc_method_name = Z_STR_P(key);
|
||||
|
@ -270,7 +270,7 @@ U_CFUNC zend_function *IntlPartsIterator_get_method(zend_object **object_ptr, ze
|
|||
|
||||
end:
|
||||
if (key == NULL) {
|
||||
STR_ALLOCA_FREE(lc_method_name, use_heap);
|
||||
ZSTR_ALLOCA_FREE(lc_method_name, use_heap);
|
||||
}
|
||||
|
||||
return ret;
|
||||
|
|
|
@ -135,7 +135,7 @@ zend_string * intl_error_get_message( intl_error* err )
|
|||
zend_string *errMessage = 0;
|
||||
|
||||
if( !err && !( err = intl_g_error_get( ) ) )
|
||||
return STR_EMPTY_ALLOC();
|
||||
return ZSTR_EMPTY_ALLOC();
|
||||
|
||||
uErrorName = u_errorName( err->code );
|
||||
|
||||
|
|
|
@ -1358,7 +1358,7 @@ php_mysqlnd_rset_field_read(void * _packet, MYSQLND_CONN_DATA * conn)
|
|||
if (meta->name != mysqlnd_empty_string) {
|
||||
meta->sname = zend_string_init(meta->name, meta->name_length, packet->persistent_alloc);
|
||||
} else {
|
||||
meta->sname = STR_EMPTY_ALLOC();
|
||||
meta->sname = ZSTR_EMPTY_ALLOC();
|
||||
}
|
||||
meta->name = meta->sname->val;
|
||||
meta->name_length = meta->sname->len;
|
||||
|
|
|
@ -343,7 +343,7 @@ zend_string *accel_new_interned_string(zend_string *str)
|
|||
idx = Z_NEXT(p->val);
|
||||
}
|
||||
|
||||
if (ZCSG(interned_strings_top) + ZEND_MM_ALIGNED_SIZE(_STR_HEADER_SIZE + str->len + 1) >=
|
||||
if (ZCSG(interned_strings_top) + ZEND_MM_ALIGNED_SIZE(_ZSTR_STRUCT_SIZE(ZSTR_LEN(str))) >=
|
||||
ZCSG(interned_strings_end)) {
|
||||
/* no memory, return the same non-interned string */
|
||||
zend_accel_error(ACCEL_LOG_WARNING, "Interned string buffer overflow");
|
||||
|
@ -356,7 +356,7 @@ zend_string *accel_new_interned_string(zend_string *str)
|
|||
ZCSG(interned_strings).nNumOfElements++;
|
||||
p = ZCSG(interned_strings).arData + idx;
|
||||
p->key = (zend_string*) ZCSG(interned_strings_top);
|
||||
ZCSG(interned_strings_top) += ZEND_MM_ALIGNED_SIZE(_STR_HEADER_SIZE + str->len + 1);
|
||||
ZCSG(interned_strings_top) += ZEND_MM_ALIGNED_SIZE(_ZSTR_STRUCT_SIZE(ZSTR_LEN(str)));
|
||||
p->h = h;
|
||||
GC_REFCOUNT(p->key) = 1;
|
||||
#if 1
|
||||
|
@ -1973,7 +1973,7 @@ static void accel_reset_pcre_cache(void)
|
|||
|
||||
ZEND_HASH_FOREACH_BUCKET(&PCRE_G(pcre_cache), p) {
|
||||
/* Remove PCRE cache entries with inconsistent keys */
|
||||
if (IS_INTERNED(p->key)) {
|
||||
if (ZSTR_IS_INTERNED(p->key)) {
|
||||
p->key = NULL;
|
||||
zend_hash_del_bucket(&PCRE_G(pcre_cache), p);
|
||||
}
|
||||
|
|
|
@ -199,14 +199,14 @@ static void *zend_file_cache_serialize_interned(zend_string *str,
|
|||
return ret;
|
||||
}
|
||||
|
||||
len = ZEND_MM_ALIGNED_SIZE(_STR_HEADER_SIZE + str->len + 1);
|
||||
len = ZEND_MM_ALIGNED_SIZE(_ZSTR_STRUCT_SIZE(ZSTR_LEN(str)));
|
||||
ret = (void*)(info->str_size | Z_UL(1));
|
||||
zend_shared_alloc_register_xlat_entry(str, ret);
|
||||
if (info->str_size + len > ((zend_string*)ZCG(mem))->len) {
|
||||
size_t new_len = info->str_size + len;
|
||||
ZCG(mem) = (void*)zend_string_realloc(
|
||||
(zend_string*)ZCG(mem),
|
||||
((_STR_HEADER_SIZE + 1 + new_len + 4095) & ~0xfff) - (_STR_HEADER_SIZE + 1),
|
||||
((_ZSTR_HEADER_SIZE + 1 + new_len + 4095) & ~0xfff) - (_ZSTR_HEADER_SIZE + 1),
|
||||
0);
|
||||
}
|
||||
memcpy(((zend_string*)ZCG(mem))->val + info->str_size, str, len);
|
||||
|
@ -717,7 +717,7 @@ int zend_file_cache_script_store(zend_persistent_script *script, int in_shm)
|
|||
mem = buf = emalloc(script->size);
|
||||
#endif
|
||||
|
||||
ZCG(mem) = zend_string_alloc(4096 - (_STR_HEADER_SIZE + 1), 0);
|
||||
ZCG(mem) = zend_string_alloc(4096 - (_ZSTR_HEADER_SIZE + 1), 0);
|
||||
|
||||
zend_shared_alloc_init_xlat_table();
|
||||
if (!in_shm) {
|
||||
|
|
|
@ -39,7 +39,7 @@
|
|||
zend_string_release(str); \
|
||||
str = new_str; \
|
||||
} else { \
|
||||
new_str = zend_accel_memdup((void*)str, _STR_HEADER_SIZE + (str)->len + 1); \
|
||||
new_str = zend_accel_memdup((void*)str, _ZSTR_STRUCT_SIZE(ZSTR_LEN(str))); \
|
||||
zend_string_release(str); \
|
||||
str = new_str; \
|
||||
zend_string_hash_val(str); \
|
||||
|
@ -47,7 +47,7 @@
|
|||
} \
|
||||
} while (0)
|
||||
#define zend_accel_memdup_string(str) do { \
|
||||
str = zend_accel_memdup(str, _STR_HEADER_SIZE + (str)->len + 1); \
|
||||
str = zend_accel_memdup(str, _ZSTR_STRUCT_SIZE(ZSTR_LEN(str))); \
|
||||
zend_string_hash_val(str); \
|
||||
GC_FLAGS(str) = IS_STR_INTERNED | IS_STR_PERMANENT; \
|
||||
} while (0)
|
||||
|
|
|
@ -31,8 +31,8 @@
|
|||
|
||||
#define ADD_ARENA_SIZE(m) ZCG(current_persistent_script)->arena_size += ZEND_ALIGNED_SIZE(m)
|
||||
|
||||
# define ADD_STRING(str) \
|
||||
ADD_DUP_SIZE((str), _STR_HEADER_SIZE + (str)->len + 1)
|
||||
# define ADD_STRING(str) ADD_DUP_SIZE((str), _ZSTR_STRUCT_SIZE(ZSTR_LEN(str)))
|
||||
|
||||
# define ADD_INTERNED_STRING(str, do_free) do { \
|
||||
if (!IS_ACCEL_INTERNED(str)) { \
|
||||
zend_string *tmp = accel_new_interned_string(str); \
|
||||
|
|
|
@ -482,7 +482,7 @@ PHPAPI pcre_cache_entry* pcre_get_compiled_regex_cache(zend_string *regex)
|
|||
* as hash keys especually for this table.
|
||||
* See bug #63180
|
||||
*/
|
||||
if (!IS_INTERNED(regex) || !(GC_FLAGS(regex) & IS_STR_PERMANENT)) {
|
||||
if (!ZSTR_IS_INTERNED(regex) || !(GC_FLAGS(regex) & IS_STR_PERMANENT)) {
|
||||
zend_string *str = zend_string_init(regex->val, regex->len, 1);
|
||||
GC_REFCOUNT(str) = 0; /* will be incremented by zend_hash_update_mem() */
|
||||
str->h = regex->h;
|
||||
|
@ -1291,7 +1291,7 @@ static zend_string *php_replace_in_subject(zval *regex, zval *replace, zval *sub
|
|||
uint32_t replace_idx;
|
||||
zend_string *subject_str = zval_get_string(subject);
|
||||
|
||||
/* FIXME: This might need to be changed to STR_EMPTY_ALLOC(). Check if this zval could be dtor()'ed somehow */
|
||||
/* FIXME: This might need to be changed to ZSTR_EMPTY_ALLOC(). Check if this zval could be dtor()'ed somehow */
|
||||
ZVAL_EMPTY_STRING(&empty_replace);
|
||||
|
||||
/* If regex is an array */
|
||||
|
|
|
@ -477,7 +477,7 @@ PS_READ_FUNC(files)
|
|||
data->st_size = sbuf.st_size;
|
||||
|
||||
if (sbuf.st_size == 0) {
|
||||
*val = STR_EMPTY_ALLOC();
|
||||
*val = ZSTR_EMPTY_ALLOC();
|
||||
return SUCCESS;
|
||||
}
|
||||
|
||||
|
@ -515,7 +515,7 @@ PS_READ_FUNC(files)
|
|||
php_error_docref(NULL, E_WARNING, "read returned less bytes than requested");
|
||||
}
|
||||
zend_string_release(*val);
|
||||
*val = STR_EMPTY_ALLOC();
|
||||
*val = ZSTR_EMPTY_ALLOC();
|
||||
return FAILURE;
|
||||
}
|
||||
|
||||
|
|
|
@ -565,7 +565,7 @@ static void php_session_save_current_state(int write) /* {{{ */
|
|||
}
|
||||
zend_string_release(val);
|
||||
} else {
|
||||
ret = PS(mod)->s_write(&PS(mod_data), PS(id), STR_EMPTY_ALLOC(), PS(gc_maxlifetime));
|
||||
ret = PS(mod)->s_write(&PS(mod_data), PS(id), ZSTR_EMPTY_ALLOC(), PS(gc_maxlifetime));
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
@ -969,7 +969,7 @@ static inline zend_string *sxe_xmlNodeListGetString(xmlDocPtr doc, xmlNodePtr li
|
|||
res = zend_string_init((char*)tmp, strlen((char *)tmp), 0);
|
||||
xmlFree(tmp);
|
||||
} else {
|
||||
res = STR_EMPTY_ALLOC();
|
||||
res = ZSTR_EMPTY_ALLOC();
|
||||
}
|
||||
|
||||
return res;
|
||||
|
|
|
@ -278,7 +278,7 @@ static zval *spl_array_get_dimension_ptr(int check_inherited, zval *object, zval
|
|||
|
||||
switch (Z_TYPE_P(offset)) {
|
||||
case IS_NULL:
|
||||
offset_key = STR_EMPTY_ALLOC();
|
||||
offset_key = ZSTR_EMPTY_ALLOC();
|
||||
goto fetch_dim_string;
|
||||
case IS_STRING:
|
||||
offset_key = Z_STR_P(offset);
|
||||
|
|
|
@ -5038,7 +5038,7 @@ PHP_FUNCTION(array_key_exists)
|
|||
}
|
||||
RETURN_FALSE;
|
||||
case IS_NULL:
|
||||
if (zend_hash_exists(array, STR_EMPTY_ALLOC())) {
|
||||
if (zend_hash_exists(array, ZSTR_EMPTY_ALLOC())) {
|
||||
RETURN_TRUE;
|
||||
}
|
||||
RETURN_FALSE;
|
||||
|
|
|
@ -174,7 +174,7 @@ static void php_browscap_parser_cb(zval *arg1, zval *arg2, zval *arg3, int callb
|
|||
(Z_STRLEN_P(arg2) == 4 && !strncasecmp(Z_STRVAL_P(arg2), "none", sizeof("none") - 1)) ||
|
||||
(Z_STRLEN_P(arg2) == 5 && !strncasecmp(Z_STRVAL_P(arg2), "false", sizeof("false") - 1))
|
||||
) {
|
||||
// TODO: USE STR_EMPTY_ALLOC()?
|
||||
// TODO: USE ZSTR_EMPTY_ALLOC()?
|
||||
ZVAL_NEW_STR(&new_property, zend_string_init("", sizeof("")-1, persistent));
|
||||
} else { /* Other than true/false setting */
|
||||
ZVAL_STR(&new_property, zend_string_dup(Z_STR_P(arg2), persistent));
|
||||
|
|
|
@ -1115,7 +1115,7 @@ PHPAPI PHP_FUNCTION(fgetss)
|
|||
|
||||
if (allowed != NULL) {
|
||||
// TODO: reimplement to avoid reallocation ???
|
||||
if (IS_INTERNED(allowed)) {
|
||||
if (ZSTR_IS_INTERNED(allowed)) {
|
||||
allowed_tags = estrndup(allowed->val, allowed->len);
|
||||
allowed_tags_len = allowed->len;
|
||||
} else {
|
||||
|
@ -1127,7 +1127,7 @@ PHPAPI PHP_FUNCTION(fgetss)
|
|||
retval_len = php_strip_tags(retval, actual_len, &stream->fgetss_state, allowed_tags, allowed_tags_len);
|
||||
|
||||
// TODO: reimplement to avoid reallocation ???
|
||||
if (allowed && IS_INTERNED(allowed)) {
|
||||
if (allowed && ZSTR_IS_INTERNED(allowed)) {
|
||||
efree(allowed_tags);
|
||||
}
|
||||
|
||||
|
|
|
@ -1303,7 +1303,7 @@ PHPAPI zend_string *php_escape_html_entities_ex(unsigned char *old, size_t oldle
|
|||
continue;
|
||||
} else {
|
||||
zend_string_free(replaced);
|
||||
return STR_EMPTY_ALLOC();
|
||||
return ZSTR_EMPTY_ALLOC();
|
||||
}
|
||||
} else { /* SUCCESS */
|
||||
mbsequence = &old[cursor_before];
|
||||
|
|
|
@ -454,7 +454,7 @@ finish:
|
|||
|
||||
user_headers = estrndup(tmp->val, tmp->len);
|
||||
|
||||
if (IS_INTERNED(tmp)) {
|
||||
if (ZSTR_IS_INTERNED(tmp)) {
|
||||
tmp = zend_string_init(tmp->val, tmp->len, 0);
|
||||
} else if (GC_REFCOUNT(tmp) > 1) {
|
||||
GC_REFCOUNT(tmp)--;
|
||||
|
|
|
@ -1081,7 +1081,7 @@ PHPAPI zend_string * _php_math_longtobase(zval *arg, int base)
|
|||
zend_ulong value;
|
||||
|
||||
if (Z_TYPE_P(arg) != IS_LONG || base < 2 || base > 36) {
|
||||
return STR_EMPTY_ALLOC();
|
||||
return ZSTR_EMPTY_ALLOC();
|
||||
}
|
||||
|
||||
value = Z_LVAL_P(arg);
|
||||
|
@ -1108,7 +1108,7 @@ PHPAPI zend_string * _php_math_zvaltobase(zval *arg, int base)
|
|||
static char digits[] = "0123456789abcdefghijklmnopqrstuvwxyz";
|
||||
|
||||
if ((Z_TYPE_P(arg) != IS_LONG && Z_TYPE_P(arg) != IS_DOUBLE) || base < 2 || base > 36) {
|
||||
return STR_EMPTY_ALLOC();
|
||||
return ZSTR_EMPTY_ALLOC();
|
||||
}
|
||||
|
||||
if (Z_TYPE_P(arg) == IS_DOUBLE) {
|
||||
|
@ -1119,7 +1119,7 @@ PHPAPI zend_string * _php_math_zvaltobase(zval *arg, int base)
|
|||
/* Don't try to convert +/- infinity */
|
||||
if (fvalue == HUGE_VAL || fvalue == -HUGE_VAL) {
|
||||
php_error_docref(NULL, E_WARNING, "Number too large");
|
||||
return STR_EMPTY_ALLOC();
|
||||
return ZSTR_EMPTY_ALLOC();
|
||||
}
|
||||
|
||||
end = ptr = buf + sizeof(buf) - 1;
|
||||
|
|
|
@ -1301,7 +1301,7 @@ PHP_FUNCTION(implode)
|
|||
return;
|
||||
}
|
||||
|
||||
delim = STR_EMPTY_ALLOC();
|
||||
delim = ZSTR_EMPTY_ALLOC();
|
||||
arr = arg1;
|
||||
} else {
|
||||
if (Z_TYPE_P(arg1) == IS_ARRAY) {
|
||||
|
@ -2130,12 +2130,12 @@ PHP_FUNCTION(strripos)
|
|||
RETURN_FALSE;
|
||||
}
|
||||
|
||||
STR_ALLOCA_ALLOC(ord_needle, 1, use_heap);
|
||||
ZSTR_ALLOCA_ALLOC(ord_needle, 1, use_heap);
|
||||
if (Z_TYPE_P(zneedle) == IS_STRING) {
|
||||
needle = Z_STR_P(zneedle);
|
||||
} else {
|
||||
if (php_needle_char(zneedle, ord_needle->val) != SUCCESS) {
|
||||
STR_ALLOCA_FREE(ord_needle, use_heap);
|
||||
ZSTR_ALLOCA_FREE(ord_needle, use_heap);
|
||||
RETURN_FALSE;
|
||||
}
|
||||
ord_needle->val[1] = '\0';
|
||||
|
@ -2143,7 +2143,7 @@ PHP_FUNCTION(strripos)
|
|||
}
|
||||
|
||||
if ((haystack->len == 0) || (needle->len == 0)) {
|
||||
STR_ALLOCA_FREE(ord_needle, use_heap);
|
||||
ZSTR_ALLOCA_FREE(ord_needle, use_heap);
|
||||
RETURN_FALSE;
|
||||
}
|
||||
|
||||
|
@ -2152,7 +2152,7 @@ PHP_FUNCTION(strripos)
|
|||
Can also avoid tolower emallocs */
|
||||
if (offset >= 0) {
|
||||
if ((size_t)offset > haystack->len) {
|
||||
STR_ALLOCA_FREE(ord_needle, use_heap);
|
||||
ZSTR_ALLOCA_FREE(ord_needle, use_heap);
|
||||
php_error_docref(NULL, E_WARNING, "Offset is greater than the length of haystack string");
|
||||
RETURN_FALSE;
|
||||
}
|
||||
|
@ -2161,7 +2161,7 @@ PHP_FUNCTION(strripos)
|
|||
} else {
|
||||
p = haystack->val;
|
||||
if (offset < -INT_MAX || (size_t)(-offset) > haystack->len) {
|
||||
STR_ALLOCA_FREE(ord_needle, use_heap);
|
||||
ZSTR_ALLOCA_FREE(ord_needle, use_heap);
|
||||
php_error_docref(NULL, E_WARNING, "Offset is greater than the length of haystack string");
|
||||
RETURN_FALSE;
|
||||
}
|
||||
|
@ -2171,12 +2171,12 @@ PHP_FUNCTION(strripos)
|
|||
*ord_needle->val = tolower(*needle->val);
|
||||
while (e >= p) {
|
||||
if (tolower(*e) == *ord_needle->val) {
|
||||
STR_ALLOCA_FREE(ord_needle, use_heap);
|
||||
ZSTR_ALLOCA_FREE(ord_needle, use_heap);
|
||||
RETURN_LONG(e - p + (offset > 0 ? offset : 0));
|
||||
}
|
||||
e--;
|
||||
}
|
||||
STR_ALLOCA_FREE(ord_needle, use_heap);
|
||||
ZSTR_ALLOCA_FREE(ord_needle, use_heap);
|
||||
RETURN_FALSE;
|
||||
}
|
||||
|
||||
|
@ -2184,7 +2184,7 @@ PHP_FUNCTION(strripos)
|
|||
if (offset >= 0) {
|
||||
if ((size_t)offset > haystack->len) {
|
||||
zend_string_release(haystack_dup);
|
||||
STR_ALLOCA_FREE(ord_needle, use_heap);
|
||||
ZSTR_ALLOCA_FREE(ord_needle, use_heap);
|
||||
php_error_docref(NULL, E_WARNING, "Offset is greater than the length of haystack string");
|
||||
RETURN_FALSE;
|
||||
}
|
||||
|
@ -2193,7 +2193,7 @@ PHP_FUNCTION(strripos)
|
|||
} else {
|
||||
if (offset < -INT_MAX || (size_t)(-offset) > haystack->len) {
|
||||
zend_string_release(haystack_dup);
|
||||
STR_ALLOCA_FREE(ord_needle, use_heap);
|
||||
ZSTR_ALLOCA_FREE(ord_needle, use_heap);
|
||||
php_error_docref(NULL, E_WARNING, "Offset is greater than the length of haystack string");
|
||||
RETURN_FALSE;
|
||||
}
|
||||
|
@ -2210,11 +2210,11 @@ PHP_FUNCTION(strripos)
|
|||
RETVAL_LONG(found - haystack_dup->val);
|
||||
zend_string_release(needle_dup);
|
||||
zend_string_release(haystack_dup);
|
||||
STR_ALLOCA_FREE(ord_needle, use_heap);
|
||||
ZSTR_ALLOCA_FREE(ord_needle, use_heap);
|
||||
} else {
|
||||
zend_string_release(needle_dup);
|
||||
zend_string_release(haystack_dup);
|
||||
STR_ALLOCA_FREE(ord_needle, use_heap);
|
||||
ZSTR_ALLOCA_FREE(ord_needle, use_heap);
|
||||
RETURN_FALSE;
|
||||
}
|
||||
}
|
||||
|
@ -3853,7 +3853,7 @@ PHPAPI zend_string *php_addslashes(zend_string *str, int should_free)
|
|||
zend_string *new_str;
|
||||
|
||||
if (!str) {
|
||||
return STR_EMPTY_ALLOC();
|
||||
return ZSTR_EMPTY_ALLOC();
|
||||
}
|
||||
|
||||
source = str->val;
|
||||
|
@ -4708,7 +4708,7 @@ PHPAPI size_t php_strip_tags_ex(char *rbuf, size_t len, int *stateptr, char *all
|
|||
rp = rbuf;
|
||||
br = 0;
|
||||
if (allow) {
|
||||
//??? if (IS_INTERNED(allow)) {
|
||||
//??? if (ZSTR_IS_INTERNED(allow)) {
|
||||
//??? allow_free = allow = zend_str_tolower_dup(allow, allow_len);
|
||||
//??? } else {
|
||||
allow_free = NULL;
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
/* Generated by re2c 0.13.7.5 */
|
||||
/* Generated by re2c 0.13.5 */
|
||||
#line 1 "ext/standard/var_unserializer.re"
|
||||
/*
|
||||
+----------------------------------------------------------------------+
|
||||
|
@ -245,10 +245,10 @@ static inline int unserialize_allowed_class(zend_string *class_name, HashTable *
|
|||
return 0;
|
||||
}
|
||||
|
||||
STR_ALLOCA_ALLOC(lcname, class_name->len, use_heap);
|
||||
ZSTR_ALLOCA_ALLOC(lcname, class_name->len, use_heap);
|
||||
zend_str_tolower_copy(lcname->val, class_name->val, class_name->len);
|
||||
res = zend_hash_exists(classes, lcname);
|
||||
STR_ALLOCA_FREE(lcname, use_heap);
|
||||
ZSTR_ALLOCA_FREE(lcname, use_heap);
|
||||
return res;
|
||||
}
|
||||
|
||||
|
@ -661,8 +661,7 @@ yy20:
|
|||
if (yybm[0+yych] & 128) {
|
||||
goto yy20;
|
||||
}
|
||||
if (yych <= '/') goto yy18;
|
||||
if (yych >= ';') goto yy18;
|
||||
if (yych != ':') goto yy18;
|
||||
yych = *++YYCURSOR;
|
||||
if (yych != '"') goto yy18;
|
||||
++YYCURSOR;
|
||||
|
@ -811,7 +810,7 @@ yy20:
|
|||
|
||||
return object_common2(UNSERIALIZE_PASSTHRU, elements);
|
||||
}
|
||||
#line 815 "ext/standard/var_unserializer.c"
|
||||
#line 814 "ext/standard/var_unserializer.c"
|
||||
yy25:
|
||||
yych = *++YYCURSOR;
|
||||
if (yych <= ',') {
|
||||
|
@ -844,7 +843,7 @@ yy27:
|
|||
return object_common2(UNSERIALIZE_PASSTHRU,
|
||||
object_common1(UNSERIALIZE_PASSTHRU, ZEND_STANDARD_CLASS_DEF_PTR));
|
||||
}
|
||||
#line 848 "ext/standard/var_unserializer.c"
|
||||
#line 847 "ext/standard/var_unserializer.c"
|
||||
yy32:
|
||||
yych = *++YYCURSOR;
|
||||
if (yych == '+') goto yy33;
|
||||
|
@ -886,7 +885,7 @@ yy34:
|
|||
|
||||
return finish_nested_data(UNSERIALIZE_PASSTHRU);
|
||||
}
|
||||
#line 890 "ext/standard/var_unserializer.c"
|
||||
#line 889 "ext/standard/var_unserializer.c"
|
||||
yy39:
|
||||
yych = *++YYCURSOR;
|
||||
if (yych == '+') goto yy40;
|
||||
|
@ -935,7 +934,7 @@ yy41:
|
|||
ZVAL_STR(rval, str);
|
||||
return 1;
|
||||
}
|
||||
#line 939 "ext/standard/var_unserializer.c"
|
||||
#line 938 "ext/standard/var_unserializer.c"
|
||||
yy46:
|
||||
yych = *++YYCURSOR;
|
||||
if (yych == '+') goto yy47;
|
||||
|
@ -983,7 +982,7 @@ yy48:
|
|||
ZVAL_STRINGL(rval, str, len);
|
||||
return 1;
|
||||
}
|
||||
#line 987 "ext/standard/var_unserializer.c"
|
||||
#line 986 "ext/standard/var_unserializer.c"
|
||||
yy53:
|
||||
yych = *++YYCURSOR;
|
||||
if (yych <= '/') {
|
||||
|
@ -1080,7 +1079,7 @@ use_double:
|
|||
ZVAL_DOUBLE(rval, zend_strtod((const char *)start + 2, NULL));
|
||||
return 1;
|
||||
}
|
||||
#line 1084 "ext/standard/var_unserializer.c"
|
||||
#line 1083 "ext/standard/var_unserializer.c"
|
||||
yy65:
|
||||
yych = *++YYCURSOR;
|
||||
if (yych <= ',') {
|
||||
|
@ -1155,7 +1154,7 @@ yy73:
|
|||
|
||||
return 1;
|
||||
}
|
||||
#line 1159 "ext/standard/var_unserializer.c"
|
||||
#line 1158 "ext/standard/var_unserializer.c"
|
||||
yy76:
|
||||
yych = *++YYCURSOR;
|
||||
if (yych == 'N') goto yy73;
|
||||
|
@ -1208,7 +1207,7 @@ yy79:
|
|||
ZVAL_LONG(rval, parse_iv(start + 2));
|
||||
return 1;
|
||||
}
|
||||
#line 1212 "ext/standard/var_unserializer.c"
|
||||
#line 1211 "ext/standard/var_unserializer.c"
|
||||
yy83:
|
||||
yych = *++YYCURSOR;
|
||||
if (yych <= '/') goto yy18;
|
||||
|
@ -1222,7 +1221,7 @@ yy83:
|
|||
ZVAL_BOOL(rval, parse_iv(start + 2));
|
||||
return 1;
|
||||
}
|
||||
#line 1226 "ext/standard/var_unserializer.c"
|
||||
#line 1225 "ext/standard/var_unserializer.c"
|
||||
yy87:
|
||||
++YYCURSOR;
|
||||
#line 577 "ext/standard/var_unserializer.re"
|
||||
|
@ -1231,7 +1230,7 @@ yy87:
|
|||
ZVAL_NULL(rval);
|
||||
return 1;
|
||||
}
|
||||
#line 1235 "ext/standard/var_unserializer.c"
|
||||
#line 1234 "ext/standard/var_unserializer.c"
|
||||
yy89:
|
||||
yych = *++YYCURSOR;
|
||||
if (yych <= ',') {
|
||||
|
@ -1277,7 +1276,7 @@ yy91:
|
|||
|
||||
return 1;
|
||||
}
|
||||
#line 1281 "ext/standard/var_unserializer.c"
|
||||
#line 1280 "ext/standard/var_unserializer.c"
|
||||
yy95:
|
||||
yych = *++YYCURSOR;
|
||||
if (yych <= ',') {
|
||||
|
@ -1322,7 +1321,7 @@ yy97:
|
|||
|
||||
return 1;
|
||||
}
|
||||
#line 1326 "ext/standard/var_unserializer.c"
|
||||
#line 1325 "ext/standard/var_unserializer.c"
|
||||
}
|
||||
#line 877 "ext/standard/var_unserializer.re"
|
||||
|
||||
|
|
|
@ -243,10 +243,10 @@ static inline int unserialize_allowed_class(zend_string *class_name, HashTable *
|
|||
return 0;
|
||||
}
|
||||
|
||||
STR_ALLOCA_ALLOC(lcname, class_name->len, use_heap);
|
||||
ZSTR_ALLOCA_ALLOC(lcname, class_name->len, use_heap);
|
||||
zend_str_tolower_copy(lcname->val, class_name->val, class_name->len);
|
||||
res = zend_hash_exists(classes, lcname);
|
||||
STR_ALLOCA_FREE(lcname, use_heap);
|
||||
ZSTR_ALLOCA_FREE(lcname, use_heap);
|
||||
return res;
|
||||
}
|
||||
|
||||
|
|
|
@ -646,7 +646,7 @@ static zend_string *php_tidy_file_to_mem(char *filename, zend_bool use_include_p
|
|||
return NULL;
|
||||
}
|
||||
if ((data = php_stream_copy_to_mem(stream, PHP_STREAM_COPY_ALL, 0)) == NULL) {
|
||||
data = STR_EMPTY_ALLOC();
|
||||
data = ZSTR_EMPTY_ALLOC();
|
||||
}
|
||||
php_stream_close(stream);
|
||||
|
||||
|
@ -928,7 +928,7 @@ static void *php_tidy_get_opt_val(PHPTidyDoc *ptdoc, TidyOption opt, TidyOptionT
|
|||
if (val) {
|
||||
return (void *) zend_string_init(val, strlen(val), 0);
|
||||
} else {
|
||||
return (void *) STR_EMPTY_ALLOC();
|
||||
return (void *) ZSTR_EMPTY_ALLOC();
|
||||
}
|
||||
}
|
||||
break;
|
||||
|
|
|
@ -720,13 +720,13 @@ static void php_wddx_push_element(void *user_data, const XML_Char *name, const X
|
|||
ent.type = ST_STRING;
|
||||
SET_STACK_VARNAME;
|
||||
|
||||
ZVAL_STR(&ent.data, STR_EMPTY_ALLOC());
|
||||
ZVAL_STR(&ent.data, ZSTR_EMPTY_ALLOC());
|
||||
wddx_stack_push((wddx_stack *)stack, &ent, sizeof(st_entry));
|
||||
} else if (!strcmp((char *)name, EL_BINARY)) {
|
||||
ent.type = ST_BINARY;
|
||||
SET_STACK_VARNAME;
|
||||
|
||||
ZVAL_STR(&ent.data, STR_EMPTY_ALLOC());
|
||||
ZVAL_STR(&ent.data, ZSTR_EMPTY_ALLOC());
|
||||
wddx_stack_push((wddx_stack *)stack, &ent, sizeof(st_entry));
|
||||
} else if (!strcmp((char *)name, EL_CHAR)) {
|
||||
int i;
|
||||
|
|
|
@ -1414,7 +1414,7 @@ PHPAPI zend_string *_php_stream_copy_to_mem(php_stream *src, size_t maxlen, int
|
|||
zend_string *result;
|
||||
|
||||
if (maxlen == 0) {
|
||||
return STR_EMPTY_ALLOC();
|
||||
return ZSTR_EMPTY_ALLOC();
|
||||
}
|
||||
|
||||
if (maxlen == PHP_STREAM_COPY_ALL) {
|
||||
|
|
|
@ -607,7 +607,7 @@ static int SendText(char *RPath, char *Subject, char *mailTo, char *mailCc, char
|
|||
data_cln = php_str_to_str(data, strlen(data), PHP_WIN32_MAIL_DOT_PATTERN, sizeof(PHP_WIN32_MAIL_DOT_PATTERN) - 1,
|
||||
PHP_WIN32_MAIL_DOT_REPLACE, sizeof(PHP_WIN32_MAIL_DOT_REPLACE) - 1);
|
||||
if (!data_cln) {
|
||||
data_cln = STR_EMPTY_ALLOC();
|
||||
data_cln = ZSTR_EMPTY_ALLOC();
|
||||
}
|
||||
|
||||
/* send message contents in 1024 chunks */
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue