From 698783861c9e402af4736993918e617b39964caa Mon Sep 17 00:00:00 2001 From: Gabi Melman Date: Mon, 17 Oct 2016 12:50:38 +0300 Subject: [PATCH] Fixed vc warning on x64 build --- include/spdlog/sinks/wincolor_sink.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/include/spdlog/sinks/wincolor_sink.h b/include/spdlog/sinks/wincolor_sink.h index e73a1ae3..5555d801 100644 --- a/include/spdlog/sinks/wincolor_sink.h +++ b/include/spdlog/sinks/wincolor_sink.h @@ -54,7 +54,7 @@ public: { auto color = colors_[msg.level]; auto orig_attribs = set_console_attribs(color); - WriteConsoleA(out_handle_, msg.formatted.data(), msg.formatted.size(), nullptr, nullptr); + WriteConsoleA(out_handle_, msg.formatted.data(), static_cast(msg.formatted.size()), nullptr, nullptr); SetConsoleTextAttribute(out_handle_, orig_attribs); //reset to orig colors } @@ -113,4 +113,4 @@ typedef wincolor_stderr_sink wincolor_stderr_sink_mt; typedef wincolor_stderr_sink wincolor_stderr_sink_st; } -} \ No newline at end of file +}