OLD | NEW |
1 // Copyright (c) 2013 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2013 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 "base/process/process_metrics.h" | 5 #include "base/process/process_metrics.h" |
6 | 6 |
7 #include <sys/resource.h> | 7 #include <sys/resource.h> |
8 #include <sys/time.h> | 8 #include <sys/time.h> |
9 | 9 |
10 #include "base/logging.h" | 10 #include "base/logging.h" |
(...skipping 50 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
61 } | 61 } |
62 limits.rlim_cur = new_limit; | 62 limits.rlim_cur = new_limit; |
63 if (setrlimit(RLIMIT_NOFILE, &limits) != 0) { | 63 if (setrlimit(RLIMIT_NOFILE, &limits) != 0) { |
64 PLOG(INFO) << "Failed to set file descriptor limit"; | 64 PLOG(INFO) << "Failed to set file descriptor limit"; |
65 } | 65 } |
66 } else { | 66 } else { |
67 PLOG(INFO) << "Failed to get file descriptor limit"; | 67 PLOG(INFO) << "Failed to get file descriptor limit"; |
68 } | 68 } |
69 } | 69 } |
70 | 70 |
| 71 size_t GetPageSize() { |
| 72 return getpagesize(); |
| 73 } |
| 74 |
71 } // namespace base | 75 } // namespace base |
OLD | NEW |