Skip to content

Commit 2e15d1f

Browse files
committed
HASH_KEY_NON_EXISTANT fix
1 parent d6ece28 commit 2e15d1f

24 files changed

+47
-47
lines changed

Zend/zend_hash.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1144,7 +1144,7 @@ ZEND_API int zend_hash_get_current_key_ex(const HashTable *ht, char **str_index,
11441144
return HASH_KEY_IS_LONG;
11451145
}
11461146
}
1147-
return HASH_KEY_NON_EXISTANT;
1147+
return HASH_KEY_NON_EXISTENT;
11481148
}
11491149

11501150
ZEND_API void zend_hash_get_current_key_zval_ex(const HashTable *ht, zval *key, HashPosition *pos) {
@@ -1181,7 +1181,7 @@ ZEND_API int zend_hash_get_current_key_type_ex(HashTable *ht, HashPosition *pos)
11811181
return HASH_KEY_IS_LONG;
11821182
}
11831183
}
1184-
return HASH_KEY_NON_EXISTANT;
1184+
return HASH_KEY_NON_EXISTENT;
11851185
}
11861186

11871187

Zend/zend_hash.h

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,7 @@
2727

2828
#define HASH_KEY_IS_STRING 1
2929
#define HASH_KEY_IS_LONG 2
30-
#define HASH_KEY_NON_EXISTANT 3
30+
#define HASH_KEY_NON_EXISTENT 3
3131

3232
#define HASH_UPDATE (1<<0)
3333
#define HASH_ADD (1<<1)
@@ -172,7 +172,7 @@ ZEND_API ulong zend_hash_next_free_element(const HashTable *ht);
172172

173173
/* traversing */
174174
#define zend_hash_has_more_elements_ex(ht, pos) \
175-
(zend_hash_get_current_key_type_ex(ht, pos) == HASH_KEY_NON_EXISTANT ? FAILURE : SUCCESS)
175+
(zend_hash_get_current_key_type_ex(ht, pos) == HASH_KEY_NON_EXISTENT ? FAILURE : SUCCESS)
176176
ZEND_API int zend_hash_move_forward_ex(HashTable *ht, HashPosition *pos);
177177
ZEND_API int zend_hash_move_backwards_ex(HashTable *ht, HashPosition *pos);
178178
ZEND_API int zend_hash_get_current_key_ex(const HashTable *ht, char **str_index, uint *str_length, ulong *num_index, zend_bool duplicate, HashPosition *pos);

Zend/zend_vm_def.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4221,7 +4221,7 @@ ZEND_VM_HANDLER(77, ZEND_FE_RESET, CONST|TMP|VAR|CV, ANY)
42214221
zend_uchar key_type;
42224222

42234223
key_type = zend_hash_get_current_key_ex(fe_ht, &str_key, &str_key_len, &int_key, 0, NULL);
4224-
if (key_type != HASH_KEY_NON_EXISTANT &&
4224+
if (key_type != HASH_KEY_NON_EXISTENT &&
42254225
(key_type == HASH_KEY_IS_LONG ||
42264226
zend_check_property_access(zobj, str_key, str_key_len-1 TSRMLS_CC) == SUCCESS)) {
42274227
break;

Zend/zend_vm_execute.h

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -2906,7 +2906,7 @@ static int ZEND_FASTCALL ZEND_FE_RESET_SPEC_CONST_HANDLER(ZEND_OPCODE_HANDLER_A
29062906
zend_uchar key_type;
29072907

29082908
key_type = zend_hash_get_current_key_ex(fe_ht, &str_key, &str_key_len, &int_key, 0, NULL);
2909-
if (key_type != HASH_KEY_NON_EXISTANT &&
2909+
if (key_type != HASH_KEY_NON_EXISTENT &&
29102910
(key_type == HASH_KEY_IS_LONG ||
29112911
zend_check_property_access(zobj, str_key, str_key_len-1 TSRMLS_CC) == SUCCESS)) {
29122912
break;
@@ -8214,7 +8214,7 @@ static int ZEND_FASTCALL ZEND_FE_RESET_SPEC_TMP_HANDLER(ZEND_OPCODE_HANDLER_ARG
82148214
zend_uchar key_type;
82158215

82168216
key_type = zend_hash_get_current_key_ex(fe_ht, &str_key, &str_key_len, &int_key, 0, NULL);
8217-
if (key_type != HASH_KEY_NON_EXISTANT &&
8217+
if (key_type != HASH_KEY_NON_EXISTENT &&
82188218
(key_type == HASH_KEY_IS_LONG ||
82198219
zend_check_property_access(zobj, str_key, str_key_len-1 TSRMLS_CC) == SUCCESS)) {
82208220
break;
@@ -13544,7 +13544,7 @@ static int ZEND_FASTCALL ZEND_FE_RESET_SPEC_VAR_HANDLER(ZEND_OPCODE_HANDLER_ARG
1354413544
zend_uchar key_type;
1354513545

1354613546
key_type = zend_hash_get_current_key_ex(fe_ht, &str_key, &str_key_len, &int_key, 0, NULL);
13547-
if (key_type != HASH_KEY_NON_EXISTANT &&
13547+
if (key_type != HASH_KEY_NON_EXISTENT &&
1354813548
(key_type == HASH_KEY_IS_LONG ||
1354913549
zend_check_property_access(zobj, str_key, str_key_len-1 TSRMLS_CC) == SUCCESS)) {
1355013550
break;
@@ -31167,7 +31167,7 @@ static int ZEND_FASTCALL ZEND_FE_RESET_SPEC_CV_HANDLER(ZEND_OPCODE_HANDLER_ARGS
3116731167
zend_uchar key_type;
3116831168

3116931169
key_type = zend_hash_get_current_key_ex(fe_ht, &str_key, &str_key_len, &int_key, 0, NULL);
31170-
if (key_type != HASH_KEY_NON_EXISTANT &&
31170+
if (key_type != HASH_KEY_NON_EXISTENT &&
3117131171
(key_type == HASH_KEY_IS_LONG ||
3117231172
zend_check_property_access(zobj, str_key, str_key_len-1 TSRMLS_CC) == SUCCESS)) {
3117331173
break;

ext/com_dotnet/com_variant.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -53,7 +53,7 @@ static void safe_array_from_zval(VARIANT *v, zval *z, int codepage TSRMLS_DC)
5353

5454
if (HASH_KEY_IS_STRING == keytype) {
5555
goto bogus;
56-
} else if (HASH_KEY_NON_EXISTANT == keytype) {
56+
} else if (HASH_KEY_NON_EXISTENT == keytype) {
5757
break;
5858
}
5959
if (intindex > max_index) {

ext/com_dotnet/com_wrapper.c

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -467,7 +467,7 @@ static void generate_dispids(php_dispatchex *disp TSRMLS_DC)
467467
/* properties */
468468
if (Z_OBJPROP_P(disp->object)) {
469469
zend_hash_internal_pointer_reset_ex(Z_OBJPROP_P(disp->object), &pos);
470-
while (HASH_KEY_NON_EXISTANT != (keytype =
470+
while (HASH_KEY_NON_EXISTENT != (keytype =
471471
zend_hash_get_current_key_ex(Z_OBJPROP_P(disp->object), &name,
472472
&namelen, &pid, 0, &pos))) {
473473
char namebuf[32];
@@ -498,7 +498,7 @@ static void generate_dispids(php_dispatchex *disp TSRMLS_DC)
498498
/* functions */
499499
if (Z_OBJCE_P(disp->object)) {
500500
zend_hash_internal_pointer_reset_ex(&Z_OBJCE_P(disp->object)->function_table, &pos);
501-
while (HASH_KEY_NON_EXISTANT != (keytype =
501+
while (HASH_KEY_NON_EXISTENT != (keytype =
502502
zend_hash_get_current_key_ex(&Z_OBJCE_P(disp->object)->function_table,
503503
&name, &namelen, &pid, 0, &pos))) {
504504

@@ -598,7 +598,7 @@ PHP_COM_DOTNET_API IDispatch *php_com_wrapper_export_as_sink(zval *val, GUID *si
598598
zend_hash_init(disp->name_to_dispid, 0, NULL, ZVAL_PTR_DTOR, 0);
599599

600600
zend_hash_internal_pointer_reset_ex(id_to_name, &pos);
601-
while (HASH_KEY_NON_EXISTANT != (keytype =
601+
while (HASH_KEY_NON_EXISTENT != (keytype =
602602
zend_hash_get_current_key_ex(id_to_name, &name, &namelen, &pid, 0, &pos))) {
603603

604604
if (keytype == HASH_KEY_IS_LONG) {

ext/hash/hash.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -597,7 +597,7 @@ PHP_FUNCTION(hash_algos)
597597

598598
array_init(return_value);
599599
for(zend_hash_internal_pointer_reset_ex(&php_hash_hashtable, &pos);
600-
(type = zend_hash_get_current_key_ex(&php_hash_hashtable, &str, &str_len, &idx, 0, &pos)) != HASH_KEY_NON_EXISTANT;
600+
(type = zend_hash_get_current_key_ex(&php_hash_hashtable, &str, &str_len, &idx, 0, &pos)) != HASH_KEY_NON_EXISTENT;
601601
zend_hash_move_forward_ex(&php_hash_hashtable, &pos)) {
602602
add_next_index_stringl(return_value, str, str_len-1, 1);
603603
}
@@ -1042,7 +1042,7 @@ PHP_MINFO_FUNCTION(hash)
10421042
long type;
10431043

10441044
for(zend_hash_internal_pointer_reset_ex(&php_hash_hashtable, &pos);
1045-
(type = zend_hash_get_current_key_ex(&php_hash_hashtable, &str, NULL, &idx, 0, &pos)) != HASH_KEY_NON_EXISTANT;
1045+
(type = zend_hash_get_current_key_ex(&php_hash_hashtable, &str, NULL, &idx, 0, &pos)) != HASH_KEY_NON_EXISTENT;
10461046
zend_hash_move_forward_ex(&php_hash_hashtable, &pos)) {
10471047
s += slprintf(s, e - s, "%s ", str);
10481048
}

ext/intl/collator/collator_convert.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -139,7 +139,7 @@ void collator_convert_hash_from_utf8_to_utf16( HashTable* hash, UErrorCode* stat
139139

140140
zend_hash_internal_pointer_reset( hash );
141141
while( ( hashKeyType = zend_hash_get_current_key( hash, &hashKey, &hashIndex, 0 ) )
142-
!= HASH_KEY_NON_EXISTANT )
142+
!= HASH_KEY_NON_EXISTENT )
143143
{
144144
/* Convert current hash item from UTF-8 to UTF-16LE. */
145145
collator_convert_hash_item_from_utf8_to_utf16(
@@ -164,7 +164,7 @@ void collator_convert_hash_from_utf16_to_utf8( HashTable* hash, UErrorCode* stat
164164

165165
zend_hash_internal_pointer_reset( hash );
166166
while( ( hashKeyType = zend_hash_get_current_key( hash, &hashKey, &hashIndex, 0 ) )
167-
!= HASH_KEY_NON_EXISTANT )
167+
!= HASH_KEY_NON_EXISTENT )
168168
{
169169
/* Convert current hash item from UTF-16LE to UTF-8. */
170170
collator_convert_hash_item_from_utf16_to_utf8(

ext/json/json.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -185,7 +185,7 @@ static int json_determine_array_type(zval **val TSRMLS_DC) /* {{{ */
185185
idx = 0;
186186
for (;; zend_hash_move_forward_ex(myht, &pos)) {
187187
i = zend_hash_get_current_key_ex(myht, &key, &key_len, &index, 0, &pos);
188-
if (i == HASH_KEY_NON_EXISTANT) {
188+
if (i == HASH_KEY_NON_EXISTENT) {
189189
break;
190190
}
191191

@@ -271,7 +271,7 @@ static void json_encode_array(smart_str *buf, zval **val, int options TSRMLS_DC)
271271
zend_hash_internal_pointer_reset_ex(myht, &pos);
272272
for (;; zend_hash_move_forward_ex(myht, &pos)) {
273273
i = zend_hash_get_current_key_ex(myht, &key, &key_len, &index, 0, &pos);
274-
if (i == HASH_KEY_NON_EXISTANT)
274+
if (i == HASH_KEY_NON_EXISTENT)
275275
break;
276276

277277
if (zend_hash_get_current_data_ex(myht, (void **) &data, &pos) == SUCCESS) {

ext/pcntl/pcntl.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -795,7 +795,7 @@ PHP_FUNCTION(pcntl_exec)
795795
snprintf(key, 100, "%ld", key_num);
796796
key_length = strlen(key);
797797
break;
798-
case HASH_KEY_NON_EXISTANT:
798+
case HASH_KEY_NON_EXISTENT:
799799
pair--;
800800
continue;
801801
}

ext/pgsql/pgsql.c

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -5338,15 +5338,15 @@ PHP_PGSQL_API int php_pgsql_convert(PGconn *pg_link, const char *table_name, con
53385338
skip_field = 0;
53395339
new_val = NULL;
53405340

5341-
if ((key_type = zend_hash_get_current_key_ex(Z_ARRVAL_P(values), &field, &field_len, &num_idx, 0, &pos)) == HASH_KEY_NON_EXISTANT) {
5341+
if ((key_type = zend_hash_get_current_key_ex(Z_ARRVAL_P(values), &field, &field_len, &num_idx, 0, &pos)) == HASH_KEY_NON_EXISTENT) {
53425342
php_error_docref(NULL TSRMLS_CC, E_WARNING, "Failed to get array key type");
53435343
err = 1;
53445344
}
53455345
if (!err && key_type == HASH_KEY_IS_LONG) {
53465346
php_error_docref(NULL TSRMLS_CC, E_WARNING, "Accepts only string key for values");
53475347
err = 1;
53485348
}
5349-
if (!err && key_type == HASH_KEY_NON_EXISTANT) {
5349+
if (!err && key_type == HASH_KEY_NON_EXISTENT) {
53505350
php_error_docref(NULL TSRMLS_CC, E_WARNING, "Accepts only string key for values");
53515351
err = 1;
53525352
}
@@ -6049,7 +6049,7 @@ PHP_PGSQL_API int php_pgsql_insert(PGconn *pg_link, const char *table, zval *var
60496049

60506050
zend_hash_internal_pointer_reset_ex(Z_ARRVAL_P(var_array), &pos);
60516051
while ((key_type = zend_hash_get_current_key_ex(Z_ARRVAL_P(var_array), &fld,
6052-
&fld_len, &num_idx, 0, &pos)) != HASH_KEY_NON_EXISTANT) {
6052+
&fld_len, &num_idx, 0, &pos)) != HASH_KEY_NON_EXISTENT) {
60536053
if (key_type == HASH_KEY_IS_LONG) {
60546054
php_error_docref(NULL TSRMLS_CC, E_NOTICE, "Expects associative array for values to be inserted");
60556055
goto cleanup;

ext/phar/dirstream.c

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -103,7 +103,7 @@ static size_t phar_dir_read(php_stream *stream, char *buf, size_t count TSRMLS_D
103103
return 0;
104104
}
105105

106-
if (HASH_KEY_NON_EXISTANT == zend_hash_get_current_key_ex(data, &key, &keylen, &unused, 0, NULL)) {
106+
if (HASH_KEY_NON_EXISTENT == zend_hash_get_current_key_ex(data, &key, &keylen, &unused, 0, NULL)) {
107107
return 0;
108108
}
109109

@@ -211,7 +211,7 @@ static php_stream *phar_make_dirstream(char *dir, HashTable *manifest TSRMLS_DC)
211211
zend_hash_internal_pointer_reset(manifest);
212212

213213
while (FAILURE != zend_hash_has_more_elements(manifest)) {
214-
if (HASH_KEY_NON_EXISTANT == zend_hash_get_current_key_ex(manifest, &key, &keylen, &unused, 0, NULL)) {
214+
if (HASH_KEY_NON_EXISTENT == zend_hash_get_current_key_ex(manifest, &key, &keylen, &unused, 0, NULL)) {
215215
break;
216216
}
217217

@@ -403,7 +403,7 @@ php_stream *phar_wrapper_open_dir(php_stream_wrapper *wrapper, char *path, char
403403
/* search for directory */
404404
zend_hash_internal_pointer_reset(&phar->manifest);
405405
while (FAILURE != zend_hash_has_more_elements(&phar->manifest)) {
406-
if (HASH_KEY_NON_EXISTANT !=
406+
if (HASH_KEY_NON_EXISTENT !=
407407
zend_hash_get_current_key_ex(
408408
&phar->manifest, &key, &keylen, &unused, 0, NULL)) {
409409
PHAR_STR(key, str_key);
@@ -637,7 +637,7 @@ int phar_wrapper_rmdir(php_stream_wrapper *wrapper, char *url, int options, php_
637637

638638
if (!entry->is_deleted) {
639639
for (zend_hash_internal_pointer_reset(&phar->manifest);
640-
HASH_KEY_NON_EXISTANT != zend_hash_get_current_key_ex(&phar->manifest, &key, &key_len, &unused, 0, NULL);
640+
HASH_KEY_NON_EXISTENT != zend_hash_get_current_key_ex(&phar->manifest, &key, &key_len, &unused, 0, NULL);
641641
zend_hash_move_forward(&phar->manifest)) {
642642

643643
PHAR_STR(key, str_key);
@@ -658,7 +658,7 @@ int phar_wrapper_rmdir(php_stream_wrapper *wrapper, char *url, int options, php_
658658
}
659659

660660
for (zend_hash_internal_pointer_reset(&phar->virtual_dirs);
661-
HASH_KEY_NON_EXISTANT != zend_hash_get_current_key_ex(&phar->virtual_dirs, &key, &key_len, &unused, 0, NULL);
661+
HASH_KEY_NON_EXISTENT != zend_hash_get_current_key_ex(&phar->virtual_dirs, &key, &key_len, &unused, 0, NULL);
662662
zend_hash_move_forward(&phar->virtual_dirs)) {
663663

664664
PHAR_STR(key, str_key);

ext/phar/phar.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1964,7 +1964,7 @@ int phar_detect_phar_fname_ext(const char *filename, int filename_len, const cha
19641964
zend_hash_internal_pointer_reset(&(PHAR_GLOBALS->phar_fname_map));
19651965

19661966
while (FAILURE != zend_hash_has_more_elements(&(PHAR_GLOBALS->phar_fname_map))) {
1967-
if (HASH_KEY_NON_EXISTANT == zend_hash_get_current_key_ex(&(PHAR_GLOBALS->phar_fname_map), &key, &keylen, &unused, 0, NULL)) {
1967+
if (HASH_KEY_NON_EXISTENT == zend_hash_get_current_key_ex(&(PHAR_GLOBALS->phar_fname_map), &key, &keylen, &unused, 0, NULL)) {
19681968
break;
19691969
}
19701970

@@ -1994,7 +1994,7 @@ int phar_detect_phar_fname_ext(const char *filename, int filename_len, const cha
19941994
zend_hash_internal_pointer_reset(&cached_phars);
19951995

19961996
while (FAILURE != zend_hash_has_more_elements(&cached_phars)) {
1997-
if (HASH_KEY_NON_EXISTANT == zend_hash_get_current_key_ex(&cached_phars, &key, &keylen, &unused, 0, NULL)) {
1997+
if (HASH_KEY_NON_EXISTENT == zend_hash_get_current_key_ex(&cached_phars, &key, &keylen, &unused, 0, NULL)) {
19981998
break;
19991999
}
20002000

ext/phar/stream.c

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -635,7 +635,7 @@ static int phar_wrapper_stat(php_stream_wrapper *wrapper, char *url, int flags,
635635

636636
zend_hash_internal_pointer_reset_ex(&phar->mounted_dirs, &pos);
637637
while (FAILURE != zend_hash_has_more_elements_ex(&phar->mounted_dirs, &pos)) {
638-
if (HASH_KEY_NON_EXISTANT == zend_hash_get_current_key_ex(&phar->mounted_dirs, &key, &keylen, &unused, 0, &pos)) {
638+
if (HASH_KEY_NON_EXISTENT == zend_hash_get_current_key_ex(&phar->mounted_dirs, &key, &keylen, &unused, 0, &pos)) {
639639
break;
640640
}
641641
PHAR_STR(key, str_key);
@@ -918,7 +918,7 @@ static int phar_wrapper_rename(php_stream_wrapper *wrapper, char *url_from, char
918918
uint to_len = strlen(resource_to->path+1);
919919

920920
for (zend_hash_internal_pointer_reset(&phar->manifest);
921-
HASH_KEY_NON_EXISTANT != (key_type = zend_hash_get_current_key_ex(&phar->manifest, &key, &key_len, &unused, 0, NULL)) &&
921+
HASH_KEY_NON_EXISTENT != (key_type = zend_hash_get_current_key_ex(&phar->manifest, &key, &key_len, &unused, 0, NULL)) &&
922922
SUCCESS == zend_hash_get_current_data(&phar->manifest, (void **) &entry);
923923
zend_hash_move_forward(&phar->manifest)) {
924924

@@ -952,7 +952,7 @@ static int phar_wrapper_rename(php_stream_wrapper *wrapper, char *url_from, char
952952
}
953953

954954
for (zend_hash_internal_pointer_reset(&phar->virtual_dirs);
955-
HASH_KEY_NON_EXISTANT != (key_type = zend_hash_get_current_key_ex(&phar->virtual_dirs, &key, &key_len, &unused, 0, NULL));
955+
HASH_KEY_NON_EXISTENT != (key_type = zend_hash_get_current_key_ex(&phar->virtual_dirs, &key, &key_len, &unused, 0, NULL));
956956
zend_hash_move_forward(&phar->virtual_dirs)) {
957957

958958
PHAR_STR(key, str_key);
@@ -979,7 +979,7 @@ static int phar_wrapper_rename(php_stream_wrapper *wrapper, char *url_from, char
979979
}
980980

981981
for (zend_hash_internal_pointer_reset(&phar->mounted_dirs);
982-
HASH_KEY_NON_EXISTANT != (key_type = zend_hash_get_current_key_ex(&phar->mounted_dirs, &key, &key_len, &unused, 0, NULL)) &&
982+
HASH_KEY_NON_EXISTENT != (key_type = zend_hash_get_current_key_ex(&phar->mounted_dirs, &key, &key_len, &unused, 0, NULL)) &&
983983
SUCCESS == zend_hash_get_current_data(&phar->mounted_dirs, (void **) &entry);
984984
zend_hash_move_forward(&phar->mounted_dirs)) {
985985

ext/phar/util.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1554,7 +1554,7 @@ phar_entry_info *phar_get_entry_info_dir(phar_archive_data *phar, char *path, in
15541554

15551555
zend_hash_internal_pointer_reset(&phar->mounted_dirs);
15561556
while (FAILURE != zend_hash_has_more_elements(&phar->mounted_dirs)) {
1557-
if (HASH_KEY_NON_EXISTANT == zend_hash_get_current_key_ex(&phar->mounted_dirs, &key, &keylen, &unused, 0, NULL)) {
1557+
if (HASH_KEY_NON_EXISTENT == zend_hash_get_current_key_ex(&phar->mounted_dirs, &key, &keylen, &unused, 0, NULL)) {
15581558
break;
15591559
}
15601560

ext/session/php_session.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -254,7 +254,7 @@ PHPAPI const ps_serializer *_php_find_ps_serializer(char *name TSRMLS_DC);
254254
int key_type; \
255255
\
256256
for (zend_hash_internal_pointer_reset(_ht); \
257-
(key_type = zend_hash_get_current_key_ex(_ht, &key, &key_length, &num_key, 0, NULL)) != HASH_KEY_NON_EXISTANT; \
257+
(key_type = zend_hash_get_current_key_ex(_ht, &key, &key_length, &num_key, 0, NULL)) != HASH_KEY_NON_EXISTENT; \
258258
zend_hash_move_forward(_ht)) { \
259259
if (key_type == HASH_KEY_IS_LONG) { \
260260
php_error_docref(NULL TSRMLS_CC, E_NOTICE, "Skipping numeric key %ld", num_key); \

ext/standard/array.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4017,7 +4017,7 @@ PHP_FUNCTION(array_rand)
40174017

40184018
/* We can't use zend_hash_index_find() because the array may have string keys or gaps. */
40194019
zend_hash_internal_pointer_reset_ex(Z_ARRVAL_P(input), &pos);
4020-
while (num_req && (key_type = zend_hash_get_current_key_ex(Z_ARRVAL_P(input), &string_key, &string_key_len, &num_key, 0, &pos)) != HASH_KEY_NON_EXISTANT) {
4020+
while (num_req && (key_type = zend_hash_get_current_key_ex(Z_ARRVAL_P(input), &string_key, &string_key_len, &num_key, 0, &pos)) != HASH_KEY_NON_EXISTENT) {
40214021

40224022
randval = php_rand(TSRMLS_C);
40234023

ext/standard/http.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -56,7 +56,7 @@ PHPAPI int php_url_encode_hash_ex(HashTable *ht, smart_str *formstr,
5656
arg_sep_len = strlen(arg_sep);
5757

5858
for (zend_hash_internal_pointer_reset(ht);
59-
(key_type = zend_hash_get_current_key_ex(ht, &key, &key_len, &idx, 0, NULL)) != HASH_KEY_NON_EXISTANT;
59+
(key_type = zend_hash_get_current_key_ex(ht, &key, &key_len, &idx, 0, NULL)) != HASH_KEY_NON_EXISTENT;
6060
zend_hash_move_forward(ht)
6161
) {
6262
if (key_type == HASH_KEY_IS_STRING && key_len && key[key_len-1] == '\0') {

ext/standard/proc_open.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -172,7 +172,7 @@ static php_process_env_t _php_array_to_envp(zval *environment, int is_persistent
172172
#endif
173173
p += el_len + 1;
174174
break;
175-
case HASH_KEY_NON_EXISTANT:
175+
case HASH_KEY_NON_EXISTENT:
176176
break;
177177
}
178178
}

ext/standard/streamsfuncs.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -583,7 +583,7 @@ PHP_FUNCTION(stream_get_wrappers)
583583
HashPosition pos;
584584
array_init(return_value);
585585
for (zend_hash_internal_pointer_reset_ex(url_stream_wrappers_hash, &pos);
586-
(key_flags = zend_hash_get_current_key_ex(url_stream_wrappers_hash, &stream_protocol, &stream_protocol_len, &num_key, 0, &pos)) != HASH_KEY_NON_EXISTANT;
586+
(key_flags = zend_hash_get_current_key_ex(url_stream_wrappers_hash, &stream_protocol, &stream_protocol_len, &num_key, 0, &pos)) != HASH_KEY_NON_EXISTENT;
587587
zend_hash_move_forward_ex(url_stream_wrappers_hash, &pos)) {
588588
if (key_flags == HASH_KEY_IS_STRING) {
589589
add_next_index_stringl(return_value, stream_protocol, stream_protocol_len - 1, 1);
@@ -668,7 +668,7 @@ static int stream_array_from_fd_set(zval *stream_array, fd_set *fds TSRMLS_DC)
668668

669669
type = zend_hash_get_current_key_ex(Z_ARRVAL_P(stream_array),
670670
&key, &key_len, &num_ind, 0, NULL);
671-
if (type == HASH_KEY_NON_EXISTANT ||
671+
if (type == HASH_KEY_NON_EXISTENT ||
672672
zend_hash_get_current_data(Z_ARRVAL_P(stream_array), (void **) &elem) == FAILURE) {
673673
continue; /* should not happen */
674674
}

ext/standard/user_filters.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -559,7 +559,7 @@ PHP_FUNCTION(stream_get_filters)
559559

560560
if (filters_hash) {
561561
for(zend_hash_internal_pointer_reset(filters_hash);
562-
(key_flags = zend_hash_get_current_key_ex(filters_hash, &filter_name, &filter_name_len, &num_key, 0, NULL)) != HASH_KEY_NON_EXISTANT;
562+
(key_flags = zend_hash_get_current_key_ex(filters_hash, &filter_name, &filter_name_len, &num_key, 0, NULL)) != HASH_KEY_NON_EXISTENT;
563563
zend_hash_move_forward(filters_hash))
564564
if (key_flags == HASH_KEY_IS_STRING) {
565565
add_next_index_stringl(return_value, filter_name, filter_name_len - 1, 1);

ext/standard/var.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -649,7 +649,7 @@ static void php_var_serialize_class(smart_str *buf, zval *struc, zval *retval_pt
649649
for (;; zend_hash_move_forward_ex(HASH_OF(retval_ptr), &pos)) {
650650
i = zend_hash_get_current_key_ex(HASH_OF(retval_ptr), &key, NULL, &index, 0, &pos);
651651

652-
if (i == HASH_KEY_NON_EXISTANT) {
652+
if (i == HASH_KEY_NON_EXISTENT) {
653653
break;
654654
}
655655

@@ -860,7 +860,7 @@ static void php_var_serialize_intern(smart_str *buf, zval *struc, HashTable *var
860860
zend_hash_internal_pointer_reset_ex(myht, &pos);
861861
for (;; zend_hash_move_forward_ex(myht, &pos)) {
862862
i = zend_hash_get_current_key_ex(myht, &key, &key_len, &index, 0, &pos);
863-
if (i == HASH_KEY_NON_EXISTANT) {
863+
if (i == HASH_KEY_NON_EXISTENT) {
864864
break;
865865
}
866866
if (incomplete_class && strcmp(key, MAGIC_MEMBER) == 0) {

0 commit comments

Comments
 (0)