diff options
author | Andrei Zmievski <andrei@php.net> | 2007-04-13 21:34:12 +0000 |
---|---|---|
committer | Andrei Zmievski <andrei@php.net> | 2007-04-13 21:34:12 +0000 |
commit | b62d120580edeaae4e50a63f44ef15ab460d42fc (patch) | |
tree | 5620ab0ac2f67a7c96f892bde987f5c5eb338b33 /ext/json/json.c | |
parent | bcd72ca5a3cb37b1679b4ecce3a833c890b51ec7 (diff) | |
download | php-git-b62d120580edeaae4e50a63f44ef15ab460d42fc.tar.gz |
Fix processing of control characters; they should be escaped as \u
sequences.
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 809d005c57..93aec133f0 100644 --- a/ext/json/json.c +++ b/ext/json/json.c @@ -303,7 +303,7 @@ static void json_escape_string(smart_str *buf, char *s, int len) break; default: { - if (us < ' ' || (us & 127) == us) + if (us >= ' ' && (us & 127) == us) { smart_str_appendc(buf, (unsigned char) us); } |