From b0ab79bc5b95725a951d1bec702b4453f8fed400 Mon Sep 17 00:00:00 2001 From: Baptiste Lepilleur Date: Sun, 15 Nov 2009 22:49:54 +0000 Subject: [PATCH] Added patch for mingw from Sebastien Vincent --- src/lib_json/json_writer.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/lib_json/json_writer.cpp b/src/lib_json/json_writer.cpp index 111caac..36983e0 100644 --- a/src/lib_json/json_writer.cpp +++ b/src/lib_json/json_writer.cpp @@ -66,7 +66,7 @@ std::string valueToString( Value::UInt value ) std::string valueToString( double value ) { char buffer[32]; -#ifdef __STDC_SECURE_LIB__ // Use secure version with visual studio 2005 to avoid warning. +#if defined(_MSC_VER) && defined(__STDC_SECURE_LIB__) // Use secure version with visual studio 2005 to avoid warning. sprintf_s(buffer, sizeof(buffer), "%#.16g", value); #else sprintf(buffer, "%#.16g", value);