From 683f42eeef9f82edcbf96349a21ed4153a80837c Mon Sep 17 00:00:00 2001 From: Sadie Powell Date: Thu, 8 Apr 2021 13:25:52 +0100 Subject: [PATCH] Use UTC in anopesmtp to fix a C++98 compat warning. --- src/tools/anopesmtp.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/tools/anopesmtp.cpp b/src/tools/anopesmtp.cpp index 396524049..d86f9c43f 100644 --- a/src/tools/anopesmtp.cpp +++ b/src/tools/anopesmtp.cpp @@ -112,9 +112,9 @@ static std::string GetTimeStamp() { char tbuf[256]; time_t t = time(NULL); - struct tm *tm = localtime(&t); + struct tm *tm = gmtime(&t); - strftime(tbuf, sizeof(tbuf) - 1, "%a, %d %b %Y %H:%M:%S %z", tm); + strftime(tbuf, sizeof(tbuf) - 1, "%a, %d %b %Y %H:%M:%S +0000", tm); return tbuf; }