]> granicus.if.org Git - pdns/commitdiff
Missed one case of localtime()
authorOtto Moerbeek <otto.moerbeek@open-xchange.com>
Tue, 24 Sep 2019 14:51:57 +0000 (16:51 +0200)
committerOtto Moerbeek <otto.moerbeek@open-xchange.com>
Tue, 24 Sep 2019 14:51:57 +0000 (16:51 +0200)
pdns/logger.cc

index dd890478b1efb536afa56e68b1be5f7a15f04219..ad64c3108456251174287214fb91098c79933cba 100644 (file)
@@ -59,7 +59,7 @@ void Logger::log(const string &msg, Urgency u)
       struct tm tm;
       time_t t;
       time(&t);
-      tm=*localtime(&t);
+      localtime_r(&t, &tm);
       strftime(buffer,sizeof(buffer),"%b %d %H:%M:%S ", &tm);
     }