Chromium Code Reviews
Help | Chromium Project | Sign in
(1)

Issue 2733005: Download filename encoding fix [try2]: (Closed)

Can't Edit
Can't Publish+Mail
Start Review
Created:
4 years, 11 months ago by Evan Stade
Modified:
3 years, 11 months ago
CC:
chromium-reviews, cbentzel+watch_chromium.org, Paul Godavari, darin-cc_chromium.org, ben+cc_chromium.org, Paweł Hajdan Jr.
Base URL:
http://src.chromium.org/git/chromium.git
Visibility:
Public.

Description

Download filename encoding fix [try2]: Fall back on other charsets when using the URL to suggest a filename. The URL should be escaped UTF-8, but may use another encoding instead. Check for empty string in DecodeWord (avoids crash). BUG=44301 TEST=see bug. Also, net_unittests. Committed: http://src.chromium.org/viewvc/chrome?view=rev&revision=49475

Patch Set 1 #

Patch Set 2 : dont try to decode ASCII filename #

Total comments: 4

Patch Set 3 : add test #

Unified diffs Side-by-side diffs Delta from patch set Stats (+40 lines, -7 lines) Patch
M chrome/browser/gtk/download_item_gtk.cc View 2 chunks +3 lines, -3 lines 0 comments Download
M net/base/net_util.cc View 1 2 4 chunks +20 lines, -4 lines 0 comments Download
M net/base/net_util_unittest.cc View 1 chunk +17 lines, -0 lines 0 comments Download
Commit: CQ not working?

Messages

Total messages: 7 (0 generated)
Evan Stade
(previous patch failed net_unittests)
4 years, 11 months ago (2010-06-09 01:20:15 UTC) #1
brettw
LGTM
4 years, 11 months ago (2010-06-09 01:38:52 UTC) #2
Evan Stade
4 years, 11 months ago (2010-06-09 18:13:45 UTC) #3
jungshik at google
Why don't you add a couple of tests (to that long array :-) in net_util_unittest.cc)? ...
4 years, 11 months ago (2010-06-09 23:29:23 UTC) #4
Evan Stade
test added. FWIW, the particular example of a google search results page is actually not ...
4 years, 11 months ago (2010-06-10 00:03:25 UTC) #5
jungshik at google
LGTM On 2010/06/10 00:03:25, Evan Stade wrote: > test added. > > FWIW, the particular ...
4 years, 11 months ago (2010-06-10 23:50:25 UTC) #6
Evan Stade
4 years, 11 months ago (2010-06-10 23:54:24 UTC) #7
> That's because there's a bug (to resolve) about 'referrer charset' not being
> passed donw to net :-).  And, the next fallback is to use the OS default
> encoding (windows-1252 in your environment if you're on English Windows) which
> happens to have the same code points for two non-ASCII characters in question
as
> ISO-8859-2/windows-1250 has (0xE1 and 0xFD for U+00E1 and U+00FD).

I'm testing this on linux, and the referrer charset *is* being passed down, and
it is iso-8859-2.
Sign in to reply to this message.

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