diff options
author | axlecrusher <josh@allensw.com> | 2017-03-03 06:34:08 -0500 |
---|---|---|
committer | GitHub <noreply@github.com> | 2017-03-03 06:34:08 -0500 |
commit | b9b38d31e42f96a86e4ac8f1b5d22a7d11d2e884 (patch) | |
tree | 199b5959b97e4b92b1292bcd6e3eac113c7a0da4 /redist/json_helpers.c | |
parent | 58b19da6848e64c9ca7aa47d8b3e0cd30db89d44 (diff) | |
parent | 294481ff114b210f3ccb436719e9595e7ffaa96b (diff) | |
download | libsurvive-b9b38d31e42f96a86e4ac8f1b5d22a7d11d2e884.tar.gz libsurvive-b9b38d31e42f96a86e4ac8f1b5d22a7d11d2e884.tar.bz2 |
Merge pull request #32 from axlecrusher/master
Remove extra asprintf parameter
Diffstat (limited to 'redist/json_helpers.c')
-rw-r--r-- | redist/json_helpers.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/redist/json_helpers.c b/redist/json_helpers.c index 74028b2..fd04203 100644 --- a/redist/json_helpers.c +++ b/redist/json_helpers.c @@ -23,7 +23,7 @@ void json_write_float_array(FILE* f, const char* tag, float* v, uint8_t count) { str1=str2; str2=NULL; } - asprintf(&str2, "%s]", str1,v[i]); + asprintf(&str2, "%s]", str1); fputs(str2,f); free(str1); free(str2); @@ -45,7 +45,7 @@ void json_write_double_array(FILE* f, const char* tag, double* v, uint8_t count) str1=str2; str2=NULL; } - asprintf(&str2, "%s]", str1,v[i]); + asprintf(&str2, "%s]", str1); fputs(str2,f); free(str1); free(str2); @@ -61,4 +61,4 @@ void json_write_float(FILE* f, const char* tag, float v) { void json_write_str(FILE* f, const char* tag, const char* v) { fprintf(f, "\"%s\":\"%s\"", tag, v); -}
\ No newline at end of file +} |