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

Side by Side Diff: base/files/platform_file.h

Issue 555503007: Cleanup: Get rid of OS_WIN/OS_POSIX ifdefs from MojoApplication (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 6 years, 3 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
(Empty)
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved.
viettrungluu 2014/09/12 00:12:45 nit: Arguably, you should update this to 2014 (and
Hajime Morrita 2014/09/12 00:39:01 Aww. Done.
2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file.
4
5 #ifndef BASE_FILES_PLATFORM_FILE_H_
6 #define BASE_FILES_PLATFORM_FILE_H_
7
8 #include "build/build_config.h"
9 #if defined(OS_WIN)
10 #include <windows.h>
11 #endif
12
13 namespace base {
14
15 #if defined(OS_WIN)
16 typedef HANDLE PlatformFile;
17
18 inline PlatformFile InvalidPlatformFile() {
viettrungluu 2014/09/12 00:12:45 Why not just use a const?
Hajime Morrita 2014/09/12 00:39:01 Done.
19 return INVALID_HANDLE_VALUE;
20 }
21
22 #elif defined(OS_POSIX)
23 typedef int PlatformFile;
24
25 inline PlatformFile InvalidPlatformFile() {
26 return -1;
27 }
28
29 #endif // defined(OS_POSIX)
30
31 } // namespace base
32
33 #endif // BASE_FILES_PLATFORM_FILE_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698