couchdb-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Sam Bisbee (Closed) (JIRA)" <j...@apache.org>
Subject [jira] [Closed] (COUCHDB-118) PATCH JSON Regression - CouchDB crash on rendering very large integers
Date Tue, 21 Feb 2012 22:56:48 GMT

     [ https://issues.apache.org/jira/browse/COUCHDB-118?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]

Sam Bisbee closed COUCHDB-118.
------------------------------


Resolved for a while. Closing.
                
> PATCH JSON Regression - CouchDB crash on rendering very large integers
> ----------------------------------------------------------------------
>
>                 Key: COUCHDB-118
>                 URL: https://issues.apache.org/jira/browse/COUCHDB-118
>             Project: CouchDB
>          Issue Type: Bug
>          Components: Database Core
>    Affects Versions: 0.9
>            Reporter: Chris Anderson
>         Attachments: huge_int_bug_test.rb, huge_int_fix.diff
>
>
> Creating documents with gigantic integers works fine, but rendering them causes a crash
as mochijson2 tries to call float(I) and Erlang is not capable of handling it. There's nothing
in the JSON spec[1] to suggest that huge integers must be rendered as float, so I removed
that guard from mochijson2. This fixes the bug.
> I included no Futon tests because the numbers we're dealing with are too large to be
managed by Javascript. However, I will attach a Ruby test that shows the bug. It is worth
noting that the Ruby test passes on old (cjson) versions of CouchDB.
> [1] http://www.ietf.org/rfc/rfc4627.txt?number=4627

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

Mime
View raw message