OLD | NEW |
1 // Copyright (c) 2010 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2010 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 #include "chrome/common/multi_process_lock.h" | 5 #include "chrome/common/multi_process_lock.h" |
6 | 6 |
| 7 #include <stdio.h> |
7 #include <sys/socket.h> | 8 #include <sys/socket.h> |
8 #include <sys/un.h> | 9 #include <sys/un.h> |
9 #include <unistd.h> | 10 #include <unistd.h> |
10 | 11 |
11 #include "base/eintr_wrapper.h" | 12 #include "base/eintr_wrapper.h" |
12 #include "base/logging.h" | 13 #include "base/logging.h" |
13 | 14 |
14 class MultiProcessLockLinux : public MultiProcessLock { | 15 class MultiProcessLockLinux : public MultiProcessLock { |
15 public: | 16 public: |
16 explicit MultiProcessLockLinux(const std::string& name) | 17 explicit MultiProcessLockLinux(const std::string& name) |
(...skipping 81 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
98 | 99 |
99 private: | 100 private: |
100 std::string name_; | 101 std::string name_; |
101 int fd_; | 102 int fd_; |
102 DISALLOW_COPY_AND_ASSIGN(MultiProcessLockLinux); | 103 DISALLOW_COPY_AND_ASSIGN(MultiProcessLockLinux); |
103 }; | 104 }; |
104 | 105 |
105 MultiProcessLock* MultiProcessLock::Create(const std::string &name) { | 106 MultiProcessLock* MultiProcessLock::Create(const std::string &name) { |
106 return new MultiProcessLockLinux(name); | 107 return new MultiProcessLockLinux(name); |
107 } | 108 } |
OLD | NEW |