diff --git a/examples/plugins/engine/ExampleWritePlugin.cpp b/examples/plugins/engine/ExampleWritePlugin.cpp index c1640cfb08..6a54485880 100644 --- a/examples/plugins/engine/ExampleWritePlugin.cpp +++ b/examples/plugins/engine/ExampleWritePlugin.cpp @@ -29,7 +29,7 @@ std::string now() #ifdef _WIN32 time_t rawTime; std::time(&rawTime); - timeInfo = std::localtime(&rawTime); + timeInfo = std::localtime_s(&rawTime); #else timeval curTime; gettimeofday(&curTime, nullptr);