Rietveld Code Review Tool
Help | Bug tracker | Discussion group | Source code | Sign in
(40)

Issue 620041: Return verbatim String when converting overflow/truncated single-valued JSON data (Closed)

Can't Edit
Can't Publish+Mail
Start Review
Created:
16 years ago by johnfargo
Modified:
15 years, 11 months ago
Reviewers:
Paul Lindner, shindig.remailer, louiscryan
Base URL:
http://svn.apache.org/repos/asf/shindig/trunk/
Visibility:
Public.

Description

See comment in code.

Patch Set 1 #

Patch Set 2 : Actual implementation. #

Unified diffs Side-by-side diffs Delta from patch set Stats (+21 lines, -2 lines) Patch
java/common/src/main/java/org/apache/shindig/common/util/JsonConversionUtil.java View 1 1 chunk +11 lines, -2 lines 0 comments Download
java/common/src/test/java/org/apache/shindig/common/util/JsonConversionUtilTest.java View 1 chunk +10 lines, -0 lines 0 comments Download

Messages

Total messages: 4
johnfargo
16 years ago (2010-03-17 21:31:55 UTC) #1
johnfargo
Actual implementation.
16 years ago (2010-03-17 22:13:23 UTC) #2
Paul Lindner
lgtm
16 years ago (2010-03-17 22:21:28 UTC) #3
fargo
16 years ago (2010-03-17 22:47:33 UTC) #4
That was actually my original impl -- but it broke a number of weird test
cases (I didn't dive into why), and in general I wanted to be as
conservative as possible with this change. Non-lossy conversions work fine
already; it's just the lossy ones that break, and AFAIK nobody's actually
relying on the lossy conversion anywhere.

On Wed, Mar 17, 2010 at 3:39 PM, <zhoresh@gmail.com> wrote:

>
> http://codereview.appspot.com/620041/diff/3001/4002
> File
>
>
java/common/src/main/java/org/apache/shindig/common/util/JsonConversionUtil.java
> (right):
>
> http://codereview.appspot.com/620041/diff/3001/4002#newcode201
>
>
java/common/src/main/java/org/apache/shindig/common/util/JsonConversionUtil.java:201:
> return value;
> Can you skip the check and just always return value for length == 1?
>
>
> http://codereview.appspot.com/620041/show
>
Sign in to reply to this message.

Powered by Google App Engine
RSS Feeds Recent Issues | This issue
This is Rietveld f62528b