From: Martin Mares Date: Wed, 22 Jul 2015 20:20:35 +0000 (+0200) Subject: JSON: Let initializers of our anonymous union be compatible with ancient GCC's X-Git-Tag: v6.5.1~1 X-Git-Url: http://mj.ucw.cz/gitweb/?a=commitdiff_plain;h=adc9a7f4352bb84148110882b20a9fab1189f0e2;p=libucw.git JSON: Let initializers of our anonymous union be compatible with ancient GCC's --- diff --git a/ucw-json/json.h b/ucw-json/json.h index 199b6537..369598b7 100644 --- a/ucw-json/json.h +++ b/ucw-json/json.h @@ -191,8 +191,8 @@ static inline struct json_node *json_new_null(struct json_context *js UNUSED) static inline struct json_node *json_new_bool(struct json_context *js UNUSED, bool value) { static const struct json_node static_bool[2] = { - [0] = { .type = JSON_BOOLEAN, .boolean = 0 }, - [1] = { .type = JSON_BOOLEAN, .boolean = 1 }, + [0] = { .type = JSON_BOOLEAN, { .boolean = 0 } }, + [1] = { .type = JSON_BOOLEAN, { .boolean = 1 } }, }; return (struct json_node *) &static_bool[value]; }