diff options
author | Ilia Alshanetsky <iliaa@php.net> | 2011-10-17 23:51:25 +0000 |
---|---|---|
committer | Ilia Alshanetsky <iliaa@php.net> | 2011-10-17 23:51:25 +0000 |
commit | 199b52c1d47ab209da56725c2dd12c308d453ca9 (patch) | |
tree | 5c49415decbba6e86645614e100dbf24b65474c3 /ext/json/json.c | |
parent | 1619ebbec63713ee6faf9032e05e232e7a24ff42 (diff) | |
download | php-git-199b52c1d47ab209da56725c2dd12c308d453ca9.tar.gz |
Fixed bug #55543 (json_encode() with JSON_NUMERIC_CHECK fails on objects with numeric string properties)
Diffstat (limited to 'ext/json/json.c')
-rw-r--r-- | ext/json/json.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/ext/json/json.c b/ext/json/json.c index 4e8fd759d4..62d20caadf 100644 --- a/ext/json/json.c +++ b/ext/json/json.c @@ -238,7 +238,7 @@ static void json_encode_array(smart_str *buf, zval **val, int options TSRMLS_DC) need_comma = 1; } - json_escape_string(buf, key, key_len - 1, options TSRMLS_CC); + json_escape_string(buf, key, key_len - 1, options & ~PHP_JSON_NUMERIC_CHECK TSRMLS_CC); smart_str_appendc(buf, ':'); php_json_encode(buf, *data, options TSRMLS_CC); |