OLD | NEW |
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 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 <dirent.h> | 5 #include <dirent.h> |
6 #include <fcntl.h> | 6 #include <fcntl.h> |
7 #include <sys/resource.h> | 7 #include <sys/resource.h> |
8 #include <sys/stat.h> | 8 #include <sys/stat.h> |
9 #include <sys/time.h> | 9 #include <sys/time.h> |
10 #include <sys/types.h> | 10 #include <sys/types.h> |
(...skipping 271 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
282 return false; | 282 return false; |
283 #endif // !defined(ADDRESS_SANITIZER) | 283 #endif // !defined(ADDRESS_SANITIZER) |
284 } | 284 } |
285 | 285 |
286 bool LinuxSandbox::HasOpenDirectories() { | 286 bool LinuxSandbox::HasOpenDirectories() { |
287 return sandbox::Credentials().HasOpenDirectory(proc_fd_); | 287 return sandbox::Credentials().HasOpenDirectory(proc_fd_); |
288 } | 288 } |
289 | 289 |
290 void LinuxSandbox::SealSandbox() { | 290 void LinuxSandbox::SealSandbox() { |
291 if (proc_fd_ >= 0) { | 291 if (proc_fd_ >= 0) { |
292 int ret = HANDLE_EINTR(close(proc_fd_)); | 292 int ret = IGNORE_EINTR(close(proc_fd_)); |
293 CHECK_EQ(0, ret); | 293 CHECK_EQ(0, ret); |
294 proc_fd_ = -1; | 294 proc_fd_ = -1; |
295 } | 295 } |
296 } | 296 } |
297 | 297 |
298 } // namespace content | 298 } // namespace content |
299 | 299 |
OLD | NEW |