diff options
| author | Ilia Alshanetsky <iliaa@php.net> | 2003-08-22 18:50:12 +0000 |
|---|---|---|
| committer | Ilia Alshanetsky <iliaa@php.net> | 2003-08-22 18:50:12 +0000 |
| commit | f94b536bc8726b05887d9a48bb835a7f8e301c38 (patch) | |
| tree | b7c5edc796396deaa4b8769249444e943dc9424e /Zend/zend_builtin_functions.c | |
| parent | ab2ebdb49bc67765df224d27405a710c1d874665 (diff) | |
| download | php-git-f94b536bc8726b05887d9a48bb835a7f8e301c38.tar.gz | |
Replace *magic number* with a much nicer define.
Diffstat (limited to 'Zend/zend_builtin_functions.c')
| -rw-r--r-- | Zend/zend_builtin_functions.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/Zend/zend_builtin_functions.c b/Zend/zend_builtin_functions.c index 13a61bb322..5c9b905323 100644 --- a/Zend/zend_builtin_functions.c +++ b/Zend/zend_builtin_functions.c @@ -509,7 +509,7 @@ ZEND_FUNCTION(define) c.flags = case_sensitive; /* non persistent */ c.name = zend_strndup((*var)->value.str.val, (*var)->value.str.len); c.name_len = (*var)->value.str.len+1; - c.module_number = 2147483647; + c.module_number = PHP_USER_CONSTANT; if (zend_register_constant(&c TSRMLS_CC) == SUCCESS) { RETURN_TRUE; } else { @@ -1343,7 +1343,7 @@ ZEND_FUNCTION(get_defined_constants) while (zend_hash_get_current_data_ex(EG(zend_constants), (void **) &val, &pos) != FAILURE) { zval *const_val; - if (val->module_number == 2147483647) { + if (val->module_number == PHP_USER_CONSTANT) { module_number = i; } else if (val->module_number > i || val->module_number < 0) { /* should not happen */ |
