You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@couchdb.apache.org by "Chris Anderson (JIRA)" <ji...@apache.org> on 2008/09/21 15:25:44 UTC

[jira] Resolved: (COUCHDB-118) PATCH JSON Regression - CouchDB crash on rendering very large integers

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

Chris Anderson resolved COUCHDB-118.
------------------------------------

    Resolution: Fixed

fixed in r697512

> 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.
-
You can reply to this email to add a comment to the issue online.