diff options
Diffstat (limited to 'data.c')
| -rw-r--r-- | data.c | 9 |
1 files changed, 9 insertions, 0 deletions
| @@ -14,6 +14,7 @@ | |||
| 14 | #include <time.h> | 14 | #include <time.h> |
| 15 | #include <sys/stat.h> | 15 | #include <sys/stat.h> |
| 16 | #include <sys/file.h> | 16 | #include <sys/file.h> |
| 17 | #include <sys/time.h> | ||
| 17 | #include <fcntl.h> | 18 | #include <fcntl.h> |
| 18 | #include <pthread.h> | 19 | #include <pthread.h> |
| 19 | 20 | ||
| @@ -870,6 +871,14 @@ double timeline_mtime(snac *snac) | |||
| 870 | } | 871 | } |
| 871 | 872 | ||
| 872 | 873 | ||
| 874 | int timeline_touch(snac *snac) | ||
| 875 | /* changes the date of the timeline index */ | ||
| 876 | { | ||
| 877 | xs *fn = xs_fmt("%s/private.idx", snac->basedir); | ||
| 878 | return utimes(fn, NULL); | ||
| 879 | } | ||
| 880 | |||
| 881 | |||
| 873 | xs_str *timeline_fn_by_md5(snac *snac, const char *md5) | 882 | xs_str *timeline_fn_by_md5(snac *snac, const char *md5) |
| 874 | /* get the filename of an entry by md5 from any timeline */ | 883 | /* get the filename of an entry by md5 from any timeline */ |
| 875 | { | 884 | { |