init_buffer(buffer, BUFSIZE);
- json_object_add_value_object(bucket_list,
- "bucket", bucket);
+ json_object_array_add(bucket_list, bucket);
json_object_add_value_int(bucket, "id", id);
set_unit_string(buffer, lower_us,
init_buffer(buffer, BUFSIZE);
- json_object_add_value_object(bucket_list,
- "bucket", bucket);
+ json_object_array_add(bucket_list, bucket);
json_object_add_value_int(bucket, "id", id);
set_unit_string(buffer, lower_us,
int write)
{
struct json_object *root = json_create_object();
- struct json_object *bucket_list = json_create_object();
+ struct json_object *bucket_list = json_object_new_array();
lat_stats_make_json_root(root, bucket_list, write);
int write)
{
struct json_object *root = json_create_object();
- struct json_object *bucket_list = json_create_object();
+ struct json_object *bucket_list = json_object_new_array();
lat_stats_make_json_root(root, bucket_list, write);
{
int i;
struct json_object *root = json_create_object();
- struct json_object *bucket_list = json_create_object();
+ struct json_object *bucket_list = json_object_new_array();
lat_stats_make_json_root(root, bucket_list, write);