From: Jérémie Galarneau Date: Thu, 16 Jun 2022 21:36:41 +0000 (-0400) Subject: Build fix: missing initializer for member 'payload' X-Git-Url: https://git.lttng.org./?a=commitdiff_plain;h=21a887ac1ec6a80b0a42440222d614d5a0f70d58;p=lttng-tools.git Build fix: missing initializer for member 'payload' gcc 5.4.0 complains that: evaluation.cpp:30:2: warning: missing initializer for member 'lttng_evaluation_comm::payload' [-Wmissing-field-initializers] The structure's members are initialized one by one. Signed-off-by: Jérémie Galarneau Change-Id: I2784138b00af34b2bc47ed28097ab32afaa379d2 --- diff --git a/src/common/evaluation.cpp b/src/common/evaluation.cpp index e6ebeec8e..2b57de62c 100644 --- a/src/common/evaluation.cpp +++ b/src/common/evaluation.cpp @@ -25,9 +25,9 @@ int lttng_evaluation_serialize(const struct lttng_evaluation *evaluation, struct lttng_payload *payload) { int ret; - struct lttng_evaluation_comm evaluation_comm = { - .type = (int8_t) evaluation->type - }; + struct lttng_evaluation_comm evaluation_comm; + + evaluation_comm.type = (int8_t) evaluation->type; ret = lttng_dynamic_buffer_append(&payload->buffer, &evaluation_comm, sizeof(evaluation_comm));