From 693df0fa344176b6cfa90cefbc43bbcae8659f93 Mon Sep 17 00:00:00 2001 From: Daniel Stenberg Date: Thu, 30 Oct 2003 09:13:04 +0000 Subject: silly me, I was meaning to do this change already as discussed on the libcurl list, we get the time in GMT and not localtime --- lib/file.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/lib/file.c b/lib/file.c index 9f312320a..99310ccea 100644 --- a/lib/file.c +++ b/lib/file.c @@ -201,11 +201,11 @@ CURLcode Curl_file(struct connectdata *conn) #ifdef HAVE_STRFTIME if(fstated) { struct tm *tm; -#ifdef HAVE_LOCALTIME_R +#ifdef HAVE_GMTIME_R struct tm buffer; - tm = (struct tm *)localtime_r((time_t *)&statbuf.st_mtime, &buffer); + tm = (struct tm *)gmtime_r((time_t *)&statbuf.st_mtime, &buffer); #else - tm = localtime((time_t *)&statbuf.st_mtime); + tm = gmtime((time_t *)&statbuf.st_mtime); #endif /* format: "Tue, 15 Nov 1994 12:45:26 GMT" */ strftime(buf, BUFSIZE-1, "Last-Modified: %a, %d %b %Y %H:%M:%S GMT\r\n", -- cgit v1.2.3