diff options
author | hiro <hiro@ee746299-78ed-0310-b773-934348b2243d> | 2014-04-18 06:26:43 +0000 |
---|---|---|
committer | hiro <hiro@ee746299-78ed-0310-b773-934348b2243d> | 2014-04-18 06:26:43 +0000 |
commit | 26b2f9567dc0bd7b70e6cc66eee800a1e0d89b73 (patch) | |
tree | 3eb93151b98eabb35e7c52b7ea6e6a79648227bd /libsylph/procheader.c | |
parent | d6433225cb188bace23a80686df3be09edaa6036 (diff) |
wrapped time_t as stime_t. stime_t will be 32-bit on win32 for backward compatibility.
git-svn-id: svn://sylpheed.sraoss.jp/sylpheed/trunk@3386 ee746299-78ed-0310-b773-934348b2243d
Diffstat (limited to 'libsylph/procheader.c')
-rw-r--r-- | libsylph/procheader.c | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/libsylph/procheader.c b/libsylph/procheader.c index 93ef99e7..96cca15c 100644 --- a/libsylph/procheader.c +++ b/libsylph/procheader.c @@ -873,7 +873,7 @@ static gint procheader_scan_date_string(const gchar *str, return -1; } -time_t procheader_date_parse(gchar *dest, const gchar *src, gint len) +stime_t procheader_date_parse(gchar *dest, const gchar *src, gint len) { static gchar monthstr[] = "JanFebMarAprMayJunJulAugSepOctNovDec"; gchar weekday[11]; @@ -951,14 +951,15 @@ time_t procheader_date_parse(gchar *dest, const gchar *src, gint len) return timer; } -void procheader_date_get_localtime(gchar *dest, gint len, const time_t timer) +void procheader_date_get_localtime(gchar *dest, gint len, const stime_t timer) { + time_t timer_ = timer; struct tm *lt; gchar *default_format = "%y/%m/%d(%a) %H:%M"; gchar *buf; gchar tmp[BUFFSIZE]; - lt = localtime(&timer); + lt = localtime(&timer_); if (!lt) { g_warning("can't get localtime of %ld\n", timer); dest[0] = '\0'; |