From: Patrick von Reth Date: Sat, 17 May 2014 13:29:05 +0000 (+0200) Subject: Fixed build with mingw X-Git-Tag: v3.2~26 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=4ccbb71ccf6b079fea6bc3bd1b99953d4b530241;p=thirdparty%2Fccache.git Fixed build with mingw _localtime32 was removed from the runtime because it was only avalible at some Windows versions. Maybe the time_t* cast could be used on all systems? --- diff --git a/util.c b/util.c index f72b38315..156c0bead 100644 --- a/util.c +++ b/util.c @@ -74,7 +74,7 @@ log_prefix(bool log_updated_time) if (log_updated_time) { gettimeofday(&tv, NULL); #ifdef __MINGW64_VERSION_MAJOR - tm = _localtime32(&tv.tv_sec); + tm = localtime((time_t*)&tv.tv_sec); #else tm = localtime(&tv.tv_sec); #endif