couchdb-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Adam Kocoloski (JIRA)" <j...@apache.org>
Subject [jira] Created: (COUCHDB-875) mochijson2 does not validate input strings after encountering an escape character
Date Tue, 31 Aug 2010 04:22:53 GMT
mochijson2 does not validate input strings after encountering an escape character
---------------------------------------------------------------------------------

                 Key: COUCHDB-875
                 URL: https://issues.apache.org/jira/browse/COUCHDB-875
             Project: CouchDB
          Issue Type: Bug
    Affects Versions: 1.0.1, 0.11.2
            Reporter: Adam Kocoloski
            Assignee: Adam Kocoloski
             Fix For: 0.11.3, 1.0.2


This example throws invalid_json (as it should, <<169>> is not a valid UTF-8 byte
sequence)

1> couch_util:json_decode(<<$", "abc", 169, $">>).                        

** exception throw: {invalid_json,<<"\"abc©\"">>}
     in function  couch_util:json_decode/1

but this example does not

2> couch_util:json_decode(<<$", "abc\\n", 169, $">>).
<<"abc\n©">>

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


Mime
View raw message