From 57feef80252b28362b3adbee1e587467b3f329b0 Mon Sep 17 00:00:00 2001 From: cnlohr Date: Sat, 29 Apr 2017 17:10:40 -0400 Subject: cleanup warnings --- redist/json_helpers.c | 28 +++++++++++++++------------- 1 file changed, 15 insertions(+), 13 deletions(-) (limited to 'redist') diff --git a/redist/json_helpers.c b/redist/json_helpers.c index 29d48bd..c52301d 100644 --- a/redist/json_helpers.c +++ b/redist/json_helpers.c @@ -50,44 +50,46 @@ void json_write_float_array(FILE* f, const char* tag, float* v, uint8_t count) { uint8_t i = 0; char * str1 = NULL; char * str2 = NULL; - asprintf(&str1,"\"%s\":[", tag); + if( asprintf(&str1,"\"%s\":[", tag) < 0 ) goto giveup; for (i=0;i