Index: base/memory/shared_memory_handle_win.cc |
diff --git a/base/memory/shared_memory_handle_win.cc b/base/memory/shared_memory_handle_win.cc |
index 571e4ef108569d091c20950224f19dc77a86c66d..e8b2687971dabfbd905a29c6cfefcc82c3c4d95a 100644 |
--- a/base/memory/shared_memory_handle_win.cc |
+++ b/base/memory/shared_memory_handle_win.cc |
@@ -9,13 +9,15 @@ |
namespace base { |
SharedMemoryHandle::SharedMemoryHandle() |
- : handle_(nullptr), pid_(kNullProcessId) {} |
+ : handle_(nullptr), pid_(kNullProcessId), ownership_passes_to_ipc_(false) {} |
SharedMemoryHandle::SharedMemoryHandle(HANDLE h, base::ProcessId pid) |
- : handle_(h), pid_(pid) {} |
+ : handle_(h), pid_(pid), ownership_passes_to_ipc_(false) {} |
SharedMemoryHandle::SharedMemoryHandle(const SharedMemoryHandle& handle) |
- : handle_(handle.handle_), pid_(handle.pid_) {} |
+ : handle_(handle.handle_), |
+ pid_(handle.pid_), |
+ ownership_passes_to_ipc_(false) {} |
SharedMemoryHandle& SharedMemoryHandle::operator=( |
const SharedMemoryHandle& handle) { |
@@ -24,6 +26,7 @@ SharedMemoryHandle& SharedMemoryHandle::operator=( |
handle_ = handle.handle_; |
pid_ = handle.pid_; |
+ ownership_passes_to_ipc_ = handle.ownership_passes_to_ipc_; |
return *this; |
} |
@@ -65,4 +68,12 @@ base::ProcessId SharedMemoryHandle::GetPID() const { |
return pid_; |
} |
+void SharedMemoryHandle::SetOwnershipPassesToIPC(bool ownership_passes) { |
+ ownership_passes_to_ipc_ = ownership_passes; |
+} |
+ |
+bool SharedMemoryHandle::OwnershipPassesToIPC() const { |
+ return ownership_passes_to_ipc_; |
+} |
+ |
} // namespace base |