From 219d1f6ac5b3e339e9f730a91ea4ad98fee15e77 Mon Sep 17 00:00:00 2001 From: =?utf8?q?J=C3=A9r=C3=A9mie=20Galarneau?= Date: Thu, 16 Jun 2022 17:36:41 -0400 Subject: [PATCH] Build fix: missing initializer for member 'payload' MIME-Version: 1.0 Content-Type: text/plain; charset=utf8 Content-Transfer-Encoding: 8bit gcc 5.4.0 complains that: error-query.cpp:777:2: warning: missing initializer for member '{anonymous}::lttng_error_query_comm::payload' [-Wmissing-field-initializers] The structure's members are initialized one by one. Signed-off-by: Jérémie Galarneau Change-Id: I1264bc2da7e8ff6ec6c740341a381b33bae643d1 --- src/common/error-query.cpp | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/common/error-query.cpp b/src/common/error-query.cpp index 1444be175..d3831ae81 100644 --- a/src/common/error-query.cpp +++ b/src/common/error-query.cpp @@ -772,9 +772,9 @@ int lttng_error_query_serialize(const struct lttng_error_query *query, struct lttng_payload *payload) { int ret; - const struct lttng_error_query_comm header = { - .target_type = (decltype(header.target_type)) query->target_type, - }; + struct lttng_error_query_comm header; + + header.target_type = (decltype(header.target_type)) query->target_type; ret = lttng_dynamic_buffer_append( &payload->buffer, &header, sizeof(header)); -- 2.34.1