| Index: base/platform_file.h
|
| diff --git a/base/platform_file.h b/base/platform_file.h
|
| index 2bfd181a16c7c0f960356710d735c2c70c4a764f..0506bc3b8f6a4a46aeba90b8d5b0270eb37bc6fa 100644
|
| --- a/base/platform_file.h
|
| +++ b/base/platform_file.h
|
| @@ -32,26 +32,29 @@ const PlatformFile kInvalidPlatformFileValue = -1;
|
| // exactly one of the five (possibly combining with other flags) when opening
|
| // or creating a file.
|
| enum PlatformFileFlags {
|
| - PLATFORM_FILE_OPEN = 1, // Opens a file, only if it exists.
|
| - PLATFORM_FILE_CREATE = 2, // Creates a new file, only if it does not
|
| - // already exist.
|
| - PLATFORM_FILE_OPEN_ALWAYS = 4, // May create a new file.
|
| - PLATFORM_FILE_CREATE_ALWAYS = 8, // May overwrite an old file.
|
| - PLATFORM_FILE_OPEN_TRUNCATED = 16, // Opens a file and truncates it, only if
|
| - // it exists.
|
| - PLATFORM_FILE_READ = 32,
|
| - PLATFORM_FILE_WRITE = 64,
|
| - PLATFORM_FILE_EXCLUSIVE_READ = 128, // EXCLUSIVE is opposite of Windows SHARE
|
| - PLATFORM_FILE_EXCLUSIVE_WRITE = 256,
|
| - PLATFORM_FILE_ASYNC = 512,
|
| - PLATFORM_FILE_TEMPORARY = 1024, // Used on Windows only
|
| - PLATFORM_FILE_HIDDEN = 2048, // Used on Windows only
|
| - PLATFORM_FILE_DELETE_ON_CLOSE = 4096,
|
| -
|
| - PLATFORM_FILE_WRITE_ATTRIBUTES = 8192, // Used on Windows only
|
| - PLATFORM_FILE_ENUMERATE = 16384, // May enumerate directory
|
| -
|
| - PLATFORM_FILE_SHARE_DELETE = 32768, // Used on Windows only
|
| + PLATFORM_FILE_OPEN = 1 << 0, // Opens a file, only if it exists.
|
| + PLATFORM_FILE_CREATE = 1 << 1, // Creates a new file, only if it
|
| + // does not already exist.
|
| + PLATFORM_FILE_OPEN_ALWAYS = 1 << 2, // May create a new file.
|
| + PLATFORM_FILE_CREATE_ALWAYS = 1 << 3, // May overwrite an old file.
|
| + PLATFORM_FILE_OPEN_TRUNCATED = 1 << 4, // Opens a file and truncates it,
|
| + // only if it exists.
|
| + PLATFORM_FILE_READ = 1 << 5,
|
| + PLATFORM_FILE_WRITE = 1 << 6,
|
| + PLATFORM_FILE_EXCLUSIVE_READ = 1 << 7, // EXCLUSIVE is opposite of Windows
|
| + // SHARE
|
| + PLATFORM_FILE_EXCLUSIVE_WRITE = 1 << 8,
|
| + PLATFORM_FILE_ASYNC = 1 << 9,
|
| + PLATFORM_FILE_TEMPORARY = 1 << 10, // Used on Windows only
|
| + PLATFORM_FILE_HIDDEN = 1 << 11, // Used on Windows only
|
| + PLATFORM_FILE_DELETE_ON_CLOSE = 1 << 12,
|
| +
|
| + PLATFORM_FILE_WRITE_ATTRIBUTES = 1 << 13, // Used on Windows only
|
| + PLATFORM_FILE_ENUMERATE = 1 << 14, // May enumerate directory
|
| +
|
| + PLATFORM_FILE_SHARE_DELETE = 1 << 15, // Used on Windows only
|
| +
|
| + PLATFORM_FILE_TERMINAL_DEVICE = 1 << 16, // Serial port flags
|
| };
|
|
|
| // PLATFORM_FILE_ERROR_ACCESS_DENIED is returned when a call fails because of
|
|
|