From: Sebastian Harl Date: Fri, 19 Sep 2014 03:38:46 +0000 (-0700) Subject: store: Fixed JSON for serialized time-series. X-Git-Tag: sysdb-0.5.0~29 X-Git-Url: https://git.tokkee.org/?p=sysdb.git;a=commitdiff_plain;h=5a12668913324db45b1d0d28f2c42bfad34af75a store: Fixed JSON for serialized time-series. Each field needs a name, add the name to the "data" field. --- diff --git a/src/core/store.c b/src/core/store.c index 401780e..e14f27c 100644 --- a/src/core/store.c +++ b/src/core/store.c @@ -555,7 +555,7 @@ ts_tojson(sdb_timeseries_t *ts, sdb_strbuf_t *buf) snprintf(end_str, sizeof(end_str), ""); end_str[sizeof(end_str) - 1] = '\0'; - sdb_strbuf_append(buf, "{\"start\": \"%s\", \"end\": \"%s\", {", + sdb_strbuf_append(buf, "{\"start\": \"%s\", \"end\": \"%s\", \"data\": {", start_str, end_str); for (i = 0; i < ts->data_names_len; ++i) {