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

Issue 48113006: Fix scoping of raw_bytes in URLRequestFileDirJob::OnListFile (Closed)

Created:
7 years, 1 month ago by fs
Modified:
7 years, 1 month ago
CC:
chromium-reviews, cbentzel+watch_chromium.org, brettw
Base URL:
https://chromium.googlesource.com/chromium/src.git@master
Visibility:
Public.

Description

Fix scoping of raw_bytes in URLRequestFileDirJob::OnListFile data.info.GetName() returns a new FilePath object, and .value() thus returns a reference to the string within that FilePath object. This means that the FilePath object can vanish before the reference to its contents is actually used - meaning whatever happens to be on the stack will be accessed. Fix by keeping a copy of the FilePath object in scope across call to GetDirectoryListingEntry. Introduced by r205019. Committed: https://src.chromium.org/viewvc/chrome?view=rev&revision=231821

Patch Set 1 #

Patch Set 2 : Use AppendASCII in unittest #

Unified diffs Side-by-side diffs Delta from patch set Stats (+40 lines, -1 line) Patch
A net/data/url_request_unittest/filedir-sentinel View 1 chunk +1 line, -0 lines 0 comments Download
M net/url_request/url_request_file_dir_job.cc View 1 chunk +2 lines, -1 line 0 comments Download
M net/url_request/url_request_unittest.cc View 1 1 chunk +37 lines, -0 lines 0 comments Download

Messages

Total messages: 10 (0 generated)
fs
7 years, 1 month ago (2013-10-28 16:52:30 UTC) #1
rvargas (doing something else)
lgtm
7 years, 1 month ago (2013-10-28 21:15:56 UTC) #2
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/fs@opera.com/48113006/1
7 years, 1 month ago (2013-10-29 08:02:43 UTC) #3
commit-bot: I haz the power
Sorry for I got bad news for ya. Compile failed with a clobber build on ...
7 years, 1 month ago (2013-10-29 08:58:30 UTC) #4
fs
Minor compilation issue with the unittest on Windows. PTAL again.
7 years, 1 month ago (2013-10-29 09:16:55 UTC) #5
rvargas (doing something else)
lgtm
7 years, 1 month ago (2013-10-29 18:18:33 UTC) #6
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/fs@opera.com/48113006/270001
7 years, 1 month ago (2013-10-30 07:36:32 UTC) #7
commit-bot: I haz the power
Retried try job too often on win7_aura for step(s) browser_tests http://build.chromium.org/p/tryserver.chromium/buildstatus?builder=win7_aura&number=94890
7 years, 1 month ago (2013-10-30 10:27:25 UTC) #8
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/fs@opera.com/48113006/270001
7 years, 1 month ago (2013-10-30 11:18:05 UTC) #9
commit-bot: I haz the power
7 years, 1 month ago (2013-10-30 13:08:37 UTC) #10
Message was sent while issue was closed.
Change committed as 231821

Powered by Google App Engine
This is Rietveld 408576698