[lttng-dev] [RFC PATCH lttng-tools v2 02/20] Clean-up: Switch enum fields in lttcomm_consumer_msg
Yannick Lamarre
ylamarre at efficios.com
Wed May 1 15:34:26 EDT 2019
Size of an enum type is not guaranteed by the C spec, which is why the
field's tpye is replaced to uin32_t.
Signed-off-by: Yannick Lamarre <ylamarre at efficios.com>
---
src/common/sessiond-comm/sessiond-comm.h | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/src/common/sessiond-comm/sessiond-comm.h b/src/common/sessiond-comm/sessiond-comm.h
index 3c815dea..47ade871 100644
--- a/src/common/sessiond-comm/sessiond-comm.h
+++ b/src/common/sessiond-comm/sessiond-comm.h
@@ -576,7 +576,7 @@ struct lttcomm_consumer_msg {
uint32_t nb_init_streams;
char name[LTTNG_SYMBOL_NAME_LEN];
/* Use splice or mmap to consume this fd */
- enum lttng_event_output output;
+ uint32_t output; /* enum lttng_event_output */
int type; /* Per cpu or metadata. */
uint64_t tracefile_size; /* bytes */
uint32_t tracefile_count; /* number of tracefiles */
@@ -603,7 +603,7 @@ struct lttcomm_consumer_msg {
} LTTNG_PACKED stream; /* Only used by Kernel. */
struct {
uint64_t net_index;
- enum lttng_stream_type type;
+ uint32_t type; /* enum lttng_stream_type */
/* Open socket to the relayd */
struct lttcomm_relayd_sock_serialized sock;
/* Tracing session id associated to the relayd. */
--
2.11.0
More information about the lttng-dev
mailing list