Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(7)

Issue 9860035: Fix handling of Unicode BOMs in JSONReader. (Closed)

Created:
8 years, 9 months ago by Robert Sesek
Modified:
8 years, 9 months ago
Reviewers:
brettw
CC:
chromium-reviews, brettw-cc_chromium.org
Visibility:
Public.

Description

Fix handling of Unicode BOMs in JSONReader. Because |char| is signed, the upper bits of the BOM bytes were getting interpreted as the sign bit. Cast to |uint8| to preserve them for proper comparison. BUG=119975 TEST=Try to install the Gmail extension. Do not get JSON error when unpacking. Committed: http://src.chromium.org/viewvc/chrome?view=rev&revision=129373

Patch Set 1 #

Patch Set 2 : Test with a real file #

Patch Set 3 : I hate Windows #

Patch Set 4 : Merge origin/master #

Unified diffs Side-by-side diffs Delta from patch set Stats (+25 lines, -3 lines) Patch
M base/base.gyp View 1 1 chunk +1 line, -0 lines 0 comments Download
M base/json/json_reader.cc View 1 1 chunk +3 lines, -2 lines 0 comments Download
M base/json/json_reader_unittest.cc View 1 2 2 chunks +21 lines, -1 line 0 comments Download

Messages

Total messages: 5 (0 generated)
Robert Sesek
8 years, 9 months ago (2012-03-27 20:08:32 UTC) #1
brettw
Can you write in the CL description what the actual problem was (I'm assuming sign ...
8 years, 9 months ago (2012-03-27 23:35:00 UTC) #2
brettw
LGTM with expanded description
8 years, 9 months ago (2012-03-27 23:35:12 UTC) #3
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/rsesek@chromium.org/9860035/7002
8 years, 9 months ago (2012-03-28 01:10:58 UTC) #4
commit-bot: I haz the power
8 years, 9 months ago (2012-03-28 04:54:47 UTC) #5
Change committed as 129373

Powered by Google App Engine
This is Rietveld 408576698