diff options
Diffstat (limited to 'src/posix_extras.h')
-rw-r--r-- | src/posix_extras.h | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/src/posix_extras.h b/src/posix_extras.h index 60b2284..a73f9fe 100644 --- a/src/posix_extras.h +++ b/src/posix_extras.h @@ -21,6 +21,7 @@ #include <dirent.h> #include <sys/stat.h> #include <sys/types.h> +#include <time.h> namespace scoville { @@ -81,6 +82,12 @@ class File { // must indeed be relative (i.e., it must not start with '/'). void UnlinkAt(const char* path) const; + // Sets the access and modification times of the file at the path relative to + // the file descriptor. The path must indeed be relative (i.e., it must not + // start with '/'). Does not follow symbolic links. + void UTimeNs(const char* path, const timespec& access, + const timespec& modification) const; + private: File() {} |