Fix: liblttng-ctl comm: lttng_event is not packed
[lttng-tools.git] / src / common / sessiond-comm / sessiond-comm.h
index b9758af006647b55c77b213aaf63b60a99e7847f..2db5ba46938625163b150b271882299aac146459 100644 (file)
@@ -278,42 +278,15 @@ struct lttcomm_session_msg {
                /* Event data */
                struct {
                        char channel_name[LTTNG_SYMBOL_NAME_LEN];
-                       struct lttng_event event LTTNG_PACKED;
-                       /* Length of following filter expression. */
-                       uint32_t expression_len;
-                       /* Length of following bytecode for filter. */
-                       uint32_t bytecode_len;
-                       /* Exclusion count (fixed-size strings). */
-                       uint32_t exclusion_count;
-                       /* Userspace probe location size. */
-                       uint32_t userspace_probe_location_len;
-                       /*
-                        * After this structure, the following variable-length
-                        * items are transmitted:
-                        * - char exclusion_names[LTTNG_SYMBOL_NAME_LEN][exclusion_count]
-                        * - char filter_expression[expression_len]
-                        * - unsigned char filter_bytecode[bytecode_len]
-                        */
+                       uint32_t length;
                } LTTNG_PACKED enable;
                struct {
                        char channel_name[LTTNG_SYMBOL_NAME_LEN];
-                       struct lttng_event event LTTNG_PACKED;
-                       /* Length of following filter expression. */
-                       uint32_t expression_len;
-                       /* Length of following bytecode for filter. */
-                       uint32_t bytecode_len;
-                       /*
-                        * After this structure, the following variable-length
-                        * items are transmitted:
-                        * - unsigned char filter_expression[expression_len]
-                        * - unsigned char filter_bytecode[bytecode_len]
-                        */
+                       uint32_t length;
                } LTTNG_PACKED disable;
                /* Create channel */
                struct {
-                       struct lttng_channel chan LTTNG_PACKED;
-                       /* struct lttng_channel_extended is already packed. */
-                       struct lttng_channel_extended extended;
+                       uint32_t length;
                } LTTNG_PACKED channel;
                /* Context */
                struct {
@@ -337,18 +310,18 @@ struct lttcomm_session_msg {
                        uint32_t size;
                } LTTNG_PACKED uri;
                struct {
-                       struct lttng_snapshot_output output LTTNG_PACKED;
+                       struct lttng_snapshot_output output;
                } LTTNG_PACKED snapshot_output;
                struct {
                        uint32_t wait;
-                       struct lttng_snapshot_output output LTTNG_PACKED;
+                       struct lttng_snapshot_output output;
                } LTTNG_PACKED snapshot_record;
                struct {
                        uint32_t nb_uri;
                        unsigned int timer_interval;    /* usec */
                } LTTNG_PACKED session_live;
                struct {
-                       struct lttng_save_session_attr attr; /* struct already packed */
+                       struct lttng_save_session_attr attr;
                } LTTNG_PACKED save_session;
                struct {
                        char shm_path[PATH_MAX];
@@ -446,11 +419,11 @@ struct lttng_event_exclusion {
        (&(_exclusion)->names[_i][0])
 
 /*
- * Event command header.
+ * Listing command header.
  */
-struct lttcomm_event_command_header {
-       /* Number of events */
-       uint32_t nb_events;
+struct lttcomm_list_command_header {
+       /* Number of elements */
+       uint32_t count;
 } LTTNG_PACKED;
 
 /*
This page took 0.024482 seconds and 4 git commands to generate.