From a6b3a2012e9c598258a295aef74d88b796c47a2b Mon Sep 17 00:00:00 2001 From: Victor Costan Date: Wed, 29 Apr 2020 22:31:41 +0000 Subject: Add some std:: qualifiers to types and functions. PiperOrigin-RevId: 309110431 --- util/windows_logger.h | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'util/windows_logger.h') diff --git a/util/windows_logger.h b/util/windows_logger.h index 9296063..26e6c7b 100644 --- a/util/windows_logger.h +++ b/util/windows_logger.h @@ -27,7 +27,7 @@ class WindowsLogger final : public Logger { ~WindowsLogger() override { std::fclose(fp_); } - void Logv(const char* format, va_list arguments) override { + void Logv(const char* format, std::va_list arguments) override { // Record the time as close to the Logv() call as possible. SYSTEMTIME now_components; ::GetLocalTime(&now_components); @@ -56,7 +56,7 @@ class WindowsLogger final : public Logger { (iteration == 0) ? stack_buffer : new char[dynamic_buffer_size]; // Print the header into the buffer. - int buffer_offset = snprintf( + int buffer_offset = std::snprintf( buffer, buffer_size, "%04d/%02d/%02d-%02d:%02d:%02d.%06d %s ", now_components.wYear, now_components.wMonth, now_components.wDay, now_components.wHour, now_components.wMinute, now_components.wSecond, @@ -92,8 +92,8 @@ class WindowsLogger final : public Logger { } // The dynamically-allocated buffer was incorrectly sized. This should - // not happen, assuming a correct implementation of (v)snprintf. Fail - // in tests, recover by truncating the log message in production. + // not happen, assuming a correct implementation of std::(v)snprintf. + // Fail in tests, recover by truncating the log message in production. assert(false); buffer_offset = buffer_size - 1; } -- cgit v1.2.1