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

Issue 2148044: PlsParser fails to read files correctly (Closed)

Can't Edit
Can't Publish+Mail
Start Review
Created:
13 years, 7 months ago by jeremy.wadsack
Modified:
13 years, 7 months ago
Base URL:
http://npr-android-app.googlecode.com/svn/trunk/
Visibility:
Public.

Description

The current implementation of PlsParser (as of r97) calls readLine twice for each loop, therefore it only looks at every other line. Because of this it can miss a URL if the file only has one on a even numbered line. Then it throw a NRE because it's trying to evaluate .equals against null returned by readline (because it's at the end of the file). This test and patch fix that.

Patch Set 1 #

Unified diffs Side-by-side diffs Delta from patch set Stats (+74 lines, -2 lines) Patch
Npr/src/org/npr/android/util/PlsParser.java View 1 chunk +3 lines, -2 lines 0 comments Download
Npr_Test/src/org/npr/android/util/PlsParserTest.java View 1 chunk +71 lines, -0 lines 0 comments Download

Messages

Total messages: 3
jeremy.wadsack
13 years, 7 months ago (2010-09-09 22:45:52 UTC) #1
Marsh
On 2010/09/09 22:45:52, jeremy.wadsack wrote: > LGTM. Please fix the 1.x branch too.
13 years, 7 months ago (2010-09-12 00:54:54 UTC) #2
jeremy.wadsack
13 years, 7 months ago (2010-09-13 20:00:22 UTC) #3
Done.

r103 on trunk and r104 on vresion_1.x.

--
Jeremy Wadsack


On Sat, Sep 11, 2010 at 5:54 PM, <marshgosnell@gmail.com> wrote:

> On 2010/09/09 22:45:52, jeremy.wadsack wrote:
>
>
> LGTM.  Please fix the 1.x branch too.
>
>
> http://codereview.appspot.com/2148044/
>
Sign in to reply to this message.

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