summaryrefslogtreecommitdiffstats
path: root/util.h
diff options
context:
space:
mode:
authorBert <ber.t@gmx.com>2011-04-07 14:33:57 +0200
committerBert <ber.t@gmx.com>2011-04-07 14:33:57 +0200
commitc21a3e3f28a5c45497d09ab27d71538b983ca535 (patch)
treec33d3b326c95f41bc9626cd2ade17c612cf47e0e /util.h
parent83bdf67d51c3f7ae996886c56556afe2a7f462e3 (diff)
downloadnsxiv-c21a3e3f28a5c45497d09ab27d71538b983ca535.tar.zst
Write thumbnail cache files on exit
Diffstat (limited to 'util.h')
-rw-r--r--util.h7
1 files changed, 7 insertions, 0 deletions
diff --git a/util.h b/util.h
index f1db6b8..e3cdef9 100644
--- a/util.h
+++ b/util.h
@@ -30,6 +30,11 @@
#define TV_TO_DOUBLE(x) ((double) ((x).tv_sec) + 0.000001 * \
(double) ((x).tv_usec))
+#define TIMESPEC_TO_TIMEVAL(tv, ts) { \
+ (tv)->tv_sec = (ts)->tv_sec; \
+ (tv)->tv_usec = (ts)->tv_nsec / 1000; \
+}
+
void* s_malloc(size_t);
void* s_realloc(void*, size_t);
@@ -38,6 +43,8 @@ void die(const char*, ...);
void size_readable(float*, const char**);
+char* absolute_path(const char*);
+
char* readline(FILE*);
#endif /* UTIL_H */