From 6a4b3f878dddb1525b59b86da7fb392ab8fdc7b2 Mon Sep 17 00:00:00 2001 From: Andreas Pasiopoulos Date: Thu, 11 Aug 2016 18:51:29 +0300 Subject: Conform to c89 --- test/suites/api/test_memory_funcs.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) (limited to 'test') diff --git a/test/suites/api/test_memory_funcs.c b/test/suites/api/test_memory_funcs.c index ac58809..7cb4b73 100644 --- a/test/suites/api/test_memory_funcs.c +++ b/test/suites/api/test_memory_funcs.c @@ -25,11 +25,12 @@ static void create_and_free_complex_object() static void create_and_free_object_with_oom() { + int i; + char key[4]; json_t *obj = json_object(); - for (int i = 0; i < 10; i++) + for (i = 0; i < 10; i++) { - char key[4]; snprintf(key, sizeof key, "%d", i); json_object_set_new(obj, key, json_integer(i)); } -- cgit v1.1