Return-Path: X-Original-To: apmail-couchdb-dev-archive@www.apache.org Delivered-To: apmail-couchdb-dev-archive@www.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id 7E8A69FCA for ; Tue, 21 Feb 2012 22:57:10 +0000 (UTC) Received: (qmail 53091 invoked by uid 500); 21 Feb 2012 22:57:09 -0000 Delivered-To: apmail-couchdb-dev-archive@couchdb.apache.org Received: (qmail 53055 invoked by uid 500); 21 Feb 2012 22:57:09 -0000 Mailing-List: contact dev-help@couchdb.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@couchdb.apache.org Delivered-To: mailing list dev@couchdb.apache.org Received: (qmail 53035 invoked by uid 99); 21 Feb 2012 22:57:09 -0000 Received: from athena.apache.org (HELO athena.apache.org) (140.211.11.136) by apache.org (qpsmtpd/0.29) with ESMTP; Tue, 21 Feb 2012 22:57:09 +0000 X-ASF-Spam-Status: No, hits=-2000.0 required=5.0 tests=ALL_TRUSTED,T_RP_MATCHES_RCVD X-Spam-Check-By: apache.org Received: from [140.211.11.116] (HELO hel.zones.apache.org) (140.211.11.116) by apache.org (qpsmtpd/0.29) with ESMTP; Tue, 21 Feb 2012 22:57:08 +0000 Received: from hel.zones.apache.org (hel.zones.apache.org [140.211.11.116]) by hel.zones.apache.org (Postfix) with ESMTP id B54721C3D90 for ; Tue, 21 Feb 2012 22:56:48 +0000 (UTC) Date: Tue, 21 Feb 2012 22:56:48 +0000 (UTC) From: "Sam Bisbee (Closed) (JIRA)" To: dev@couchdb.apache.org Message-ID: <1703013230.1627.1329865008744.JavaMail.tomcat@hel.zones.apache.org> Subject: [jira] [Closed] (COUCHDB-118) PATCH JSON Regression - CouchDB crash on rendering very large integers MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit X-JIRA-FingerPrint: 30527f35849b9dde25b450d4833f0394 [ 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