aboutsummaryrefslogtreecommitdiff
path: root/src/posix_extras.h
diff options
context:
space:
mode:
authorGravatar Benjamin Barenblat <bbaren@mit.edu>2016-02-20 15:27:41 -0500
committerGravatar Benjamin Barenblat <bbaren@mit.edu>2016-02-21 20:38:02 -0500
commitae657efd38d9fcf21b9fddc83c83d095e4f284b7 (patch)
tree464ec0500f14a4bb280a69ebc26d806d87b0d6f5 /src/posix_extras.h
parentf4b0c2e93a2f45b548465dba84b257bcb3b41446 (diff)
Unify File::OpenAt functions
Diffstat (limited to 'src/posix_extras.h')
-rw-r--r--src/posix_extras.h4
1 files changed, 3 insertions, 1 deletions
diff --git a/src/posix_extras.h b/src/posix_extras.h
index f4e7c69..9bcbe51 100644
--- a/src/posix_extras.h
+++ b/src/posix_extras.h
@@ -68,7 +68,9 @@ class File {
// Calls openat(2) on the path relative to the file descriptor. The path must
// indeed be relative (i.e., it must not start with '/').
- File OpenAt(const char* path, int flags) const;
+ File OpenAt(const char* const path, const int flags) const {
+ return OpenAt(path, flags, 0);
+ }
File OpenAt(const char* path, int flags, mode_t mode) const;
// Removes the file at the path relative to the file descriptor. The path