diff options
author | Vincent Sanders <vince@kyllikki.org> | 2014-05-15 01:18:52 +0100 |
---|---|---|
committer | Vincent Sanders <vince@kyllikki.org> | 2014-05-15 01:18:52 +0100 |
commit | ef00272e2ffb8ffcf03e740f74691fecb682060d (patch) | |
tree | d1ba29cf118a7f4c905762813d3985131fbacd34 /utils/config.h | |
parent | a4be7f7d1abe5b75d3dacfbf00adf3bd937bc4c1 (diff) | |
download | netsurf-ef00272e2ffb8ffcf03e740f74691fecb682060d.tar.gz netsurf-ef00272e2ffb8ffcf03e740f74691fecb682060d.tar.bz2 |
add helpers for time_t reading/writing
Diffstat (limited to 'utils/config.h')
-rw-r--r-- | utils/config.h | 10 |
1 files changed, 6 insertions, 4 deletions
diff --git a/utils/config.h b/utils/config.h index cc4f75191..c0a3c0d1b 100644 --- a/utils/config.h +++ b/utils/config.h @@ -38,13 +38,15 @@ char *strndup(const char *s, size_t n); char *strcasestr(const char *haystack, const char *needle); #endif -#if (defined(riscos) || defined(_WIN32)) +/* Although these platforms might have strftime or strptime they + * appear not to support the time_t seconds format specifier. + */ +#if (defined(_WIN32) || defined(riscos) || defined(__HAIKU__) || defined(__BEOS__) || defined(__amigaos4__) || defined(__AMIGA__) || defined(__MINT__)) #undef HAVE_STRPTIME -#define strptime nsc_time_strptime -struct tm; -char *nsc_time_strptime(const char *s, const char *format, struct tm *tm); +#undef HAVE_STRFTIME #else #define HAVE_STRPTIME +#define HAVE_STRFTIME #endif /* For some reason, UnixLib defines this unconditionally. |