Issue metadata
Sign in to add a comment
|
ImportantFileWriter.FailedWriteWithObserver leaks a *.tmp file in current working directory |
||||||||||||||||||||
Issue descriptionChrome Version: 58.0.3010.0 OS: Windows What steps will reproduce the problem? (1) Run base_unittests. (2) Run "dir *.tmp" What is the expected result? Expect that no files are found. What happens instead? There is a .tmp file created by each run of base_unittests.
,
Feb 22 2017
For the record, what was the culprit CL that introduced this problem?
,
Feb 22 2017
https://codereview.chromium.org/2299523003/ introduced this problem. Working on a fix in https://codereview.chromium.org/2711523002/
,
Feb 22 2017
The following revision refers to this bug: https://chromium.googlesource.com/chromium/src.git/+/05db50c5c72b8368af872b768cb637c294e99f44 commit 05db50c5c72b8368af872b768cb637c294e99f44 Author: proberge <proberge@chromium.org> Date: Wed Feb 22 23:24:01 2017 Fix ImportantFileWriter leaking a .tmp file when passed an invalid path When passed an invalid path (ex. "bad/../path"), ImportantFileWriter creates a temp file, sees that it's invalid, then returns without deleting it. The file being invalid is an implementation detail of base::File's Initialize() method, which sets an error field to FILE_ERROR_ACCESS_DENIED if the file's path contains the parent ".." operator. This stops ImportantFileWriterTest.FailedWriteWithObserver from leaking a temp file. BUG= 691388 Review-Url: https://codereview.chromium.org/2711523002 Cr-Commit-Position: refs/heads/master@{#452266} [modify] https://crrev.com/05db50c5c72b8368af872b768cb637c294e99f44/base/files/important_file_writer.cc
,
Feb 23 2017
Thanks for finding this issue @wez, I'm sure all Windows developers will appreciate not getting temp files in their git status :)
,
Feb 23 2017
|
|||||||||||||||||||||
►
Sign in to add a comment |
|||||||||||||||||||||
Comment 1 by w...@chromium.org
, Feb 17 2017Status: Assigned (was: Untriaged)
Summary: ImportantFileWriter.FailedWriteWithObserver leaks a *.tmp file in current working directory (was: Something in base_unittests leaks a *.tmp file in )