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

Side by Side Diff: base/memory/shared_memory_handle.h

Issue 1328963002: Build shared_memory_mac.cc and shared_memory_handle_mac.cc for iOS (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 5 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
« no previous file with comments | « base/memory/BUILD.gn ('k') | base/memory/shared_memory_handle_mac.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2015 The Chromium Authors. All rights reserved. 1 // Copyright 2015 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #ifndef BASE_MEMORY_SHARED_MEMORY_HANDLE_H_ 5 #ifndef BASE_MEMORY_SHARED_MEMORY_HANDLE_H_
6 #define BASE_MEMORY_SHARED_MEMORY_HANDLE_H_ 6 #define BASE_MEMORY_SHARED_MEMORY_HANDLE_H_
7 7
8 #include "build/build_config.h" 8 #include "build/build_config.h"
9 9
10 #if defined(OS_WIN) 10 #if defined(OS_WIN)
11 #include <windows.h> 11 #include <windows.h>
12 #elif defined(OS_MACOSX) && !defined(OS_IOS) 12 #elif defined(OS_MACOSX)
13 #include <sys/types.h> 13 #include <sys/types.h>
14 #include "base/base_export.h" 14 #include "base/base_export.h"
15 #include "base/file_descriptor_posix.h" 15 #include "base/file_descriptor_posix.h"
16 #include "base/macros.h" 16 #include "base/macros.h"
17 #elif defined(OS_POSIX) 17 #elif defined(OS_POSIX)
18 #include <sys/types.h> 18 #include <sys/types.h>
19 #include "base/file_descriptor_posix.h" 19 #include "base/file_descriptor_posix.h"
20 #endif 20 #endif
21 21
22 namespace base { 22 namespace base {
23 23
24 class Pickle; 24 class Pickle;
25 25
26 // SharedMemoryHandle is a platform specific type which represents 26 // SharedMemoryHandle is a platform specific type which represents
27 // the underlying OS handle to a shared memory segment. 27 // the underlying OS handle to a shared memory segment.
28 #if defined(OS_WIN) 28 #if defined(OS_WIN)
29 typedef HANDLE SharedMemoryHandle; 29 typedef HANDLE SharedMemoryHandle;
30 #elif defined(OS_POSIX) && !(defined(OS_MACOSX) && !defined(OS_IOS)) 30 #elif defined(OS_POSIX) && !defined(OS_MACOSX)
31 typedef FileDescriptor SharedMemoryHandle; 31 typedef FileDescriptor SharedMemoryHandle;
32 #else 32 #else
33 class BASE_EXPORT SharedMemoryHandle { 33 class BASE_EXPORT SharedMemoryHandle {
34 public: 34 public:
35 enum Type { 35 enum Type {
36 // Indicates that the SharedMemoryHandle is backed by a POSIX fd. 36 // Indicates that the SharedMemoryHandle is backed by a POSIX fd.
37 POSIX, 37 POSIX,
38 // Indicates that the SharedMemoryHandle is backed by the Mach primitive 38 // Indicates that the SharedMemoryHandle is backed by the Mach primitive
39 // "memory object". 39 // "memory object".
40 MACH, 40 MACH,
(...skipping 47 matching lines...) Expand 10 before | Expand all | Expand 10 after
88 88
89 private: 89 private:
90 Type type_; 90 Type type_;
91 FileDescriptor file_descriptor_; 91 FileDescriptor file_descriptor_;
92 }; 92 };
93 #endif 93 #endif
94 94
95 } // namespace base 95 } // namespace base
96 96
97 #endif // BASE_MEMORY_SHARED_MEMORY_HANDLE_H_ 97 #endif // BASE_MEMORY_SHARED_MEMORY_HANDLE_H_
OLDNEW
« no previous file with comments | « base/memory/BUILD.gn ('k') | base/memory/shared_memory_handle_mac.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698