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

Issue 668022: Change default fopen() on Windows from fopen_s() to fsopen(,,_SH_DENYNO). (Closed)

Created:
10 years, 9 months ago by Dirk Pranke
Modified:
9 years, 7 months ago
CC:
chromium-reviews_googlegroups.com, brettw+cc_chromium.org
Visibility:
Public.

Description

Change default fopen() on Windows from fopen_s() to fsopen(,,_SH_DENYNO). fopen_s() won't let you open a file that is open by another process. This has the unfortunate property of triggering a race condition in Python exposed by running run-webkit-tests using a lot of threads and spawning off image_diff. There doesn't seem to be a good reason to disallow files that are open in other processes, so I'm changing this. BUG=none TEST=run_webkit_tests doesn't produce "image_diff: can't open file" errors R=darin@chromium.org Committed: http://src.chromium.org/viewvc/chrome?view=rev&revision=40710

Patch Set 1 #

Patch Set 2 : simplify to single-line implementations #

Unified diffs Side-by-side diffs Delta from patch set Stats (+2 lines, -10 lines) Patch
M base/file_util_win.cc View 1 1 chunk +2 lines, -10 lines 0 comments Download

Messages

Total messages: 2 (0 generated)
Dirk Pranke
10 years, 9 months ago (2010-03-04 02:29:16 UTC) #1
darin (slow to review)
10 years, 9 months ago (2010-03-04 07:26:08 UTC) #2
LGTM

Powered by Google App Engine
This is Rietveld 408576698