]> granicus.if.org Git - jq/commitdiff
Fix bug caused by 8ca07a0
authorNicolas Williams <nico@cryptonector.com>
Wed, 24 Dec 2014 08:24:53 +0000 (02:24 -0600)
committerNicolas Williams <nico@cryptonector.com>
Wed, 24 Dec 2014 08:25:11 +0000 (02:25 -0600)
jv_parse.c

index 4497c42758ae75713dc28f7dcadc3c0a9362e9e8..0a06dc18ceda5f0afd899e29d0db253403c8b5d4 100644 (file)
@@ -257,7 +257,7 @@ static pfunc found_string(struct jv_parser* p) {
         return "Invalid escape";
       }
     } else {
-      if (c < 0x001f)
+      if (c > 0 && c < 0x001f)
         return "Invalid string: control characters from U+0000 through U+001F must be escaped";
       *out++ = c;
     }