Commit dffb1d04 authored by Victor Costan's avatar Victor Costan Committed by Commit Bot

base: Remove default mode from base::File::Lock().

The distinction between kShared and kExplicit is large enough that there
are significant readability advantages to having the default be explicit
in the code.

Bug: 1125315
Change-Id: I965c1c04eaa3dbd26191847f800adbbf7a0cf35f
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/2394198Reviewed-by: default avatarWez <wez@chromium.org>
Commit-Queue: Victor Costan <pwnall@chromium.org>
Cr-Commit-Position: refs/heads/master@{#806478}
parent 7fe8cc67
...@@ -299,7 +299,7 @@ class BASE_EXPORT File { ...@@ -299,7 +299,7 @@ class BASE_EXPORT File {
// * Within a process, locking the same file (by the same or new handle) // * Within a process, locking the same file (by the same or new handle)
// will succeed. The new lock replaces the old lock. // will succeed. The new lock replaces the old lock.
// * Closing any descriptor on a given file releases the lock. // * Closing any descriptor on a given file releases the lock.
Error Lock(LockMode mode = LockMode::kExclusive); Error Lock(LockMode mode);
// Unlock a file previously locked. // Unlock a file previously locked.
Error Unlock(); Error Unlock();
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment