From c652b6ad29757857be328071ad7f9ca86d5275d4 Mon Sep 17 00:00:00 2001 From: Eric Haszlakiewicz Date: Sun, 24 Dec 2017 14:42:58 -0500 Subject: [PATCH] PR#394: fix breakage with VS build. --- json_object.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/json_object.c b/json_object.c index 52e8b76..8287163 100644 --- a/json_object.c +++ b/json_object.c @@ -809,6 +809,7 @@ static int json_object_double_to_json_string_format(struct json_object* jso, else { const char *std_format = "%.17g"; + int format_drops_decimals = 0; if (!format) { @@ -833,7 +834,6 @@ static int json_object_double_to_json_string_format(struct json_object* jso, else p = strchr(buf, '.'); - int format_drops_decimals = 0; if (format == std_format || strstr(format, ".0f") == NULL) format_drops_decimals = 1; -- 2.49.0