# Disable -Wshadow for that file.
AM_CFLAGS += -Wno-shadow
+AM_CFLAGS += -Wno-missing-field-initializers
+
AM_CPPFLAGS += $(PYTHON_INCLUDE)
EXTRA_DIST = lttng.i.in
sizeof(rotate_streams.stream_count));
rotate_streams = (typeof(rotate_streams)) {
.stream_count = be32toh(rotate_streams.stream_count),
+ .new_chunk_id = LTTNG_OPTIONAL_INIT_UNSET,
};
/*
.pid = UINT32_MAX,
.cmd_header_size = 0,
.data_size = 0,
+ .fd_count = 0,
};
DBG("End of clear command: replying to client");
.cmd_header_size =
sizeof(struct lttcomm_session_destroy_command_header),
.data_size = 0,
+ .fd_count = 0,
};
size_t payload_size_before_location;
int ret;
lttcomm_consumer_msg msg = {
.cmd_type = LTTNG_CONSUMER_OPEN_CHANNEL_PACKETS,
+ .u = {},
};
msg.u.open_channel_packets.key = key;
int ret;
struct lttcomm_consumer_msg msg = {
.cmd_type = LTTNG_CONSUMER_INIT,
+ .u = {},
};
LTTNG_ASSERT(socket);
enum lttng_trace_chunk_status tc_status;
struct lttcomm_consumer_msg msg = {
.cmd_type = LTTNG_CONSUMER_CREATE_TRACE_CHUNK,
+ .u = {},
};
msg.u.create_trace_chunk.session_id = session_id;
enum lttng_trace_chunk_status chunk_status;
lttcomm_consumer_msg msg = {
.cmd_type = LTTNG_CONSUMER_CLOSE_TRACE_CHUNK,
+ .u = {},
};
msg.u.close_trace_chunk.session_id = session_id;
enum lttng_trace_chunk_status chunk_status;
lttcomm_consumer_msg msg = {
.cmd_type = LTTNG_CONSUMER_TRACE_CHUNK_EXISTS,
+ .u = {},
};
msg.u.trace_chunk_exists.session_id = session_id;
struct ust_reg_wait_node *wait_node = NULL, *tmp_wait_node;
struct ust_reg_wait_queue wait_queue = {
.count = 0,
+ .head = {},
};
struct thread_notifiers *notifiers = (thread_notifiers *) data;
LTTNG_KERNEL_ABI_COUNTER_BITNESS_64,
.number_dimensions = 1,
.global_sum_step = 0,
+ .dimensions = {},
+ .coalesce_hits = 0,
+ .padding = {},
};
error_counter_conf.dimensions[0].size = kernel_state.number_indices;
error_counter_conf.dimensions[0].has_underflow = false;
unsigned int trigger_count, i;
const struct lttng_credentials creds = {
.uid = LTTNG_OPTIONAL_INIT_VALUE(0),
+ .gid = LTTNG_OPTIONAL_INIT_UNSET,
};
DBG("Unregistering all triggers");
{
.name = (char *) "lttng-ring-buffer-client-discard",
.load_policy = KERNEL_MODULE_PROPERTY_LOAD_POLICY_REQUIRED,
+ .loaded = false,
},
{
.name = (char *) "lttng-ring-buffer-client-overwrite",
.load_policy = KERNEL_MODULE_PROPERTY_LOAD_POLICY_REQUIRED,
+ .loaded = false,
},
{
.name = (char *) "lttng-ring-buffer-metadata-client",
.load_policy = KERNEL_MODULE_PROPERTY_LOAD_POLICY_REQUIRED,
+ .loaded = false,
},
{
.name = (char *) "lttng-ring-buffer-client-mmap-discard",
.load_policy = KERNEL_MODULE_PROPERTY_LOAD_POLICY_REQUIRED,
+ .loaded = false,
},
{
.name = (char *) "lttng-ring-buffer-client-mmap-overwrite",
.load_policy = KERNEL_MODULE_PROPERTY_LOAD_POLICY_REQUIRED,
+ .loaded = false,
},
{
.name = (char *) "lttng-ring-buffer-metadata-mmap-client",
.load_policy = KERNEL_MODULE_PROPERTY_LOAD_POLICY_REQUIRED,
+ .loaded = false,
},
{
.name = (char *) "lttng-ring-buffer-event_notifier-client",
.load_policy = KERNEL_MODULE_PROPERTY_LOAD_POLICY_OPTIONAL,
+ .loaded = false,
},
{
.name = (char *) "lttng-counter-client-percpu-64-modular",
.load_policy = KERNEL_MODULE_PROPERTY_LOAD_POLICY_OPTIONAL,
+ .loaded = false,
},
{
.name = (char *) "lttng-counter-client-percpu-32-modular",
.load_policy = KERNEL_MODULE_PROPERTY_LOAD_POLICY_OPTIONAL,
+ .loaded = false,
},
};
{
.name = (char *) "lttng-probe-asoc",
.load_policy = KERNEL_MODULE_PROPERTY_LOAD_POLICY_OPTIONAL,
+ .loaded = false,
},
{
.name = (char *) "lttng-probe-block",
.load_policy = KERNEL_MODULE_PROPERTY_LOAD_POLICY_OPTIONAL,
+ .loaded = false,
},
{
.name = (char *) "lttng-probe-btrfs",
.load_policy = KERNEL_MODULE_PROPERTY_LOAD_POLICY_OPTIONAL,
+ .loaded = false,
},
{
.name = (char *) "lttng-probe-compaction",
.load_policy = KERNEL_MODULE_PROPERTY_LOAD_POLICY_OPTIONAL,
+ .loaded = false,
},
{
.name = (char *) "lttng-probe-ext3",
.load_policy = KERNEL_MODULE_PROPERTY_LOAD_POLICY_OPTIONAL,
+ .loaded = false,
},
{
.name = (char *) "lttng-probe-ext4",
.load_policy = KERNEL_MODULE_PROPERTY_LOAD_POLICY_OPTIONAL,
+ .loaded = false,
},
{
.name = (char *) "lttng-probe-gpio",
.load_policy = KERNEL_MODULE_PROPERTY_LOAD_POLICY_OPTIONAL,
+ .loaded = false,
},
{
.name = (char *) "lttng-probe-i2c",
.load_policy = KERNEL_MODULE_PROPERTY_LOAD_POLICY_OPTIONAL,
+ .loaded = false,
},
{
.name = (char *) "lttng-probe-irq",
.load_policy = KERNEL_MODULE_PROPERTY_LOAD_POLICY_OPTIONAL,
+ .loaded = false,
},
{
.name = (char *) "lttng-probe-jbd",
.load_policy = KERNEL_MODULE_PROPERTY_LOAD_POLICY_OPTIONAL,
+ .loaded = false,
},
{
.name = (char *) "lttng-probe-jbd2",
.load_policy = KERNEL_MODULE_PROPERTY_LOAD_POLICY_OPTIONAL,
+ .loaded = false,
},
{
.name = (char *) "lttng-probe-kmem",
.load_policy = KERNEL_MODULE_PROPERTY_LOAD_POLICY_OPTIONAL,
+ .loaded = false,
},
{
.name = (char *) "lttng-probe-kvm",
.load_policy = KERNEL_MODULE_PROPERTY_LOAD_POLICY_OPTIONAL,
+ .loaded = false,
},
{
.name = (char *) "lttng-probe-kvm-x86",
.load_policy = KERNEL_MODULE_PROPERTY_LOAD_POLICY_OPTIONAL,
+ .loaded = false,
},
{
.name = (char *) "lttng-probe-kvm-x86-mmu",
.load_policy = KERNEL_MODULE_PROPERTY_LOAD_POLICY_OPTIONAL,
+ .loaded = false,
},
{
.name = (char *) "lttng-probe-lock",
.load_policy = KERNEL_MODULE_PROPERTY_LOAD_POLICY_OPTIONAL,
+ .loaded = false,
},
{
.name = (char *) "lttng-probe-module",
.load_policy = KERNEL_MODULE_PROPERTY_LOAD_POLICY_OPTIONAL,
+ .loaded = false,
},
{
.name = (char *) "lttng-probe-napi",
.load_policy = KERNEL_MODULE_PROPERTY_LOAD_POLICY_OPTIONAL,
+ .loaded = false,
},
{
.name = (char *) "lttng-probe-net",
.load_policy = KERNEL_MODULE_PROPERTY_LOAD_POLICY_OPTIONAL,
+ .loaded = false,
},
{
.name = (char *) "lttng-probe-power",
.load_policy = KERNEL_MODULE_PROPERTY_LOAD_POLICY_OPTIONAL,
+ .loaded = false,
},
{
.name = (char *) "lttng-probe-preemptirq",
.load_policy = KERNEL_MODULE_PROPERTY_LOAD_POLICY_OPTIONAL,
+ .loaded = false,
},
{
.name = (char *) "lttng-probe-printk",
.load_policy = KERNEL_MODULE_PROPERTY_LOAD_POLICY_OPTIONAL,
+ .loaded = false,
},
{
.name = (char *) "lttng-probe-random",
.load_policy = KERNEL_MODULE_PROPERTY_LOAD_POLICY_OPTIONAL,
+ .loaded = false,
},
{
.name = (char *) "lttng-probe-rcu",
.load_policy = KERNEL_MODULE_PROPERTY_LOAD_POLICY_OPTIONAL,
+ .loaded = false,
},
{
.name = (char *) "lttng-probe-regmap",
.load_policy = KERNEL_MODULE_PROPERTY_LOAD_POLICY_OPTIONAL,
+ .loaded = false,
},
{
.name = (char *) "lttng-probe-regulator",
.load_policy = KERNEL_MODULE_PROPERTY_LOAD_POLICY_OPTIONAL,
+ .loaded = false,
},
{
.name = (char *) "lttng-probe-rpm",
.load_policy = KERNEL_MODULE_PROPERTY_LOAD_POLICY_OPTIONAL,
+ .loaded = false,
},
{
.name = (char *) "lttng-probe-sched",
.load_policy = KERNEL_MODULE_PROPERTY_LOAD_POLICY_OPTIONAL,
+ .loaded = false,
},
{
.name = (char *) "lttng-probe-scsi",
.load_policy = KERNEL_MODULE_PROPERTY_LOAD_POLICY_OPTIONAL,
+ .loaded = false,
},
{
.name = (char *) "lttng-probe-signal",
.load_policy = KERNEL_MODULE_PROPERTY_LOAD_POLICY_OPTIONAL,
+ .loaded = false,
},
{
.name = (char *) "lttng-probe-skb",
.load_policy = KERNEL_MODULE_PROPERTY_LOAD_POLICY_OPTIONAL,
+ .loaded = false,
},
{
.name = (char *) "lttng-probe-sock",
.load_policy = KERNEL_MODULE_PROPERTY_LOAD_POLICY_OPTIONAL,
+ .loaded = false,
},
{
.name = (char *) "lttng-probe-statedump",
.load_policy = KERNEL_MODULE_PROPERTY_LOAD_POLICY_OPTIONAL,
+ .loaded = false,
},
{
.name = (char *) "lttng-probe-sunrpc",
.load_policy = KERNEL_MODULE_PROPERTY_LOAD_POLICY_OPTIONAL,
+ .loaded = false,
},
{
.name = (char *) "lttng-probe-timer",
.load_policy = KERNEL_MODULE_PROPERTY_LOAD_POLICY_OPTIONAL,
+ .loaded = false,
},
{
.name = (char *) "lttng-probe-udp",
.load_policy = KERNEL_MODULE_PROPERTY_LOAD_POLICY_OPTIONAL,
+ .loaded = false,
},
{
.name = (char *) "lttng-probe-vmscan",
.load_policy = KERNEL_MODULE_PROPERTY_LOAD_POLICY_OPTIONAL,
+ .loaded = false,
},
{
.name = (char *) "lttng-probe-v4l2",
.load_policy = KERNEL_MODULE_PROPERTY_LOAD_POLICY_OPTIONAL,
+ .loaded = false,
},
{
.name = (char *) "lttng-probe-workqueue",
.load_policy = KERNEL_MODULE_PROPERTY_LOAD_POLICY_OPTIONAL,
+ .loaded = false,
},
{
.name = (char *) "lttng-probe-writeback",
.load_policy = KERNEL_MODULE_PROPERTY_LOAD_POLICY_OPTIONAL,
+ .loaded = false,
},
{
.name = (char *) "lttng-probe-x86-irq-vectors",
.load_policy = KERNEL_MODULE_PROPERTY_LOAD_POLICY_OPTIONAL,
+ .loaded = false,
},
{
.name = (char *) "lttng-probe-x86-exceptions",
.load_policy = KERNEL_MODULE_PROPERTY_LOAD_POLICY_OPTIONAL,
+ .loaded = false,
},
};
struct lttng_evaluation *evaluation = NULL;
struct notification_client_list client_list = {
.lock = PTHREAD_MUTEX_INITIALIZER,
+ .ref = {},
+ .condition = NULL,
+ .triggers_list = {},
+ .clients_list = {},
+ .notification_trigger_clients_ht = NULL,
+ .notification_trigger_clients_ht_node = {},
+ .rcu_node = {},
};
- struct notification_client_list_element client_list_element = { 0 };
+ struct notification_client_list_element client_list_element = {};
uid_t object_uid = 0;
gid_t object_gid = 0;
struct notification_thread_state *state,
int pipe, enum lttng_domain_type domain)
{
- struct lttng_poll_event events = {0};
+ struct lttng_poll_event events = {};
int ret;
ret = lttng_poll_create(&events, 1, LTTNG_CLOEXEC);
struct lttng_notification_channel_message msg = {
.type = (int8_t) LTTNG_NOTIFICATION_CHANNEL_MESSAGE_TYPE_COMMAND_REPLY,
.size = sizeof(reply),
+ .fds = 0,
};
char buffer[sizeof(msg) + sizeof(reply)];
enum client_transmission_status transmission_status;
const struct lttng_notification_channel_message msg_header = {
.type = LTTNG_NOTIFICATION_CHANNEL_MESSAGE_TYPE_HANDSHAKE,
.size = sizeof(handshake_reply),
+ .fds = 0,
};
enum lttng_notification_channel_status status =
LTTNG_NOTIFICATION_CHANNEL_STATUS_OK;
int ret = 0;
const struct lttng_notification_channel_message msg = {
.type = (int8_t) LTTNG_NOTIFICATION_CHANNEL_MESSAGE_TYPE_NOTIFICATION_DROPPED,
+ .size = 0,
+ .fds = 0,
};
ASSERT_LOCKED(client->lock);
};
struct lttng_notification_channel_message msg_header = {
.type = (int8_t) LTTNG_NOTIFICATION_CHANNEL_MESSAGE_TYPE_NOTIFICATION,
+ .size = 0,
+ .fds = 0,
};
const struct lttng_credentials *trigger_creds =
lttng_trigger_get_credentials(trigger);
.daemonize = false,
.sig_parent = false,
- .tracing_group_name = { (char *) DEFAULT_TRACING_GROUP },
- .kmod_probes_list = { nullptr },
- .kmod_extra_probes_list = { nullptr },
-
- .rundir = { nullptr },
-
- .apps_unix_sock_path = { nullptr },
- .client_unix_sock_path = { nullptr },
- .wait_shm_path = { nullptr },
- .health_unix_sock_path = { nullptr },
- .lttng_ust_clock_plugin = { nullptr },
- .pid_file_path = { nullptr },
- .lock_file_path = { nullptr },
- .load_session_path = { nullptr },
- .agent_port_file_path = { nullptr },
-
- .consumerd32_path = { nullptr },
- .consumerd32_bin_path = { nullptr },
- .consumerd32_lib_dir = { nullptr },
- .consumerd32_err_unix_sock_path = { nullptr },
- .consumerd32_cmd_unix_sock_path = { nullptr },
-
- .consumerd64_path = { nullptr },
- .consumerd64_bin_path = { nullptr },
- .consumerd64_lib_dir = { nullptr },
- .consumerd64_err_unix_sock_path = { nullptr },
- .consumerd64_cmd_unix_sock_path = { nullptr },
-
- .kconsumerd_path = { nullptr },
- .kconsumerd_err_unix_sock_path = { nullptr },
- .kconsumerd_cmd_unix_sock_path = { nullptr },
+ .tracing_group_name = { (char *) DEFAULT_TRACING_GROUP, false },
+
+ .kmod_probes_list = { nullptr, false },
+ .kmod_extra_probes_list = { nullptr, false },
+
+ .rundir = { nullptr, false },
+
+ .apps_unix_sock_path = { nullptr, false },
+ .client_unix_sock_path = { nullptr, false },
+ .wait_shm_path = { nullptr, false },
+ .health_unix_sock_path = { nullptr, false },
+ .lttng_ust_clock_plugin = { nullptr, false },
+ .pid_file_path = { nullptr, false },
+ .lock_file_path = { nullptr, false },
+ .load_session_path = { nullptr, false },
+ .agent_port_file_path = { nullptr, false },
+
+ .consumerd32_path = { nullptr, false },
+ .consumerd32_bin_path = { nullptr, false },
+ .consumerd32_lib_dir = { nullptr, false },
+ .consumerd32_err_unix_sock_path = { nullptr, false },
+ .consumerd32_cmd_unix_sock_path = { nullptr, false },
+
+ .consumerd64_path = { nullptr, false },
+ .consumerd64_bin_path = { nullptr, false },
+ .consumerd64_lib_dir = { nullptr, false },
+ .consumerd64_err_unix_sock_path = { nullptr, false },
+ .consumerd64_cmd_unix_sock_path = { nullptr, false },
+
+ .kconsumerd_path = { nullptr, false },
+ .kconsumerd_err_unix_sock_path = { nullptr, false },
+ .kconsumerd_cmd_unix_sock_path = { nullptr, false },
};
static
int consumed_args = -1;
struct lttng_kernel_probe_location *kernel_probe_location = NULL;
struct lttng_userspace_probe_location *userspace_probe_location = NULL;
- struct parse_event_rule_res res = { 0 };
+ struct parse_event_rule_res res = {};
struct lttng_event_expr *event_expr = NULL;
struct filter_parser_ctx *parser_ctx = NULL;
struct lttng_log_level_rule *log_level_rule = NULL;
{ "help", 'h', POPT_ARG_NONE, 0, OPT_HELP, 0, 0, },
{ "session", 's', POPT_ARG_STRING, &opt_session_name, 0, 0, 0},
{ "list-options", 0, POPT_ARG_NONE, NULL, OPT_LIST_OPTIONS, 0, 0, },
- { "list-commands", 0, POPT_ARG_NONE, NULL, OPT_LIST_COMMANDS},
+ { "list-commands", 0, POPT_ARG_NONE, NULL, OPT_LIST_COMMANDS, NULL, NULL},
{ 0, 0, 0, 0, 0, 0, 0, },
};
{ "help", 'h', POPT_ARG_NONE, 0, OPT_HELP, 0, 0, },
{ "session", 's', POPT_ARG_STRING, &opt_session_name, 0, 0, 0},
{ "list-options", 0, POPT_ARG_NONE, NULL, OPT_LIST_OPTIONS, 0, 0, },
- { "list-commands", 0, POPT_ARG_NONE, NULL, OPT_LIST_COMMANDS},
+ { "list-commands", 0, POPT_ARG_NONE, NULL, OPT_LIST_COMMANDS, NULL, NULL},
{ 0, 0, 0, 0, 0, 0, 0, },
};
{"name", 'n', POPT_ARG_STRING, &opt_output_name, 0, 0, 0},
{"max-size", 'm', POPT_ARG_STRING, 0, OPT_MAX_SIZE, 0, 0},
{"list-options", 0, POPT_ARG_NONE, NULL, OPT_LIST_OPTIONS, NULL, NULL},
- {"list-commands", 0, POPT_ARG_NONE, NULL, OPT_LIST_COMMANDS},
+ {"list-commands", 0, POPT_ARG_NONE, NULL, OPT_LIST_COMMANDS, NULL, NULL},
{0, 0, 0, 0, 0, 0, 0}
};
{
int ret;
size_t name_len;
- struct lttng_channel_comm channel_comm = { 0 };
+ struct lttng_channel_comm channel_comm = {};
struct lttng_channel_extended *extended;
assert(channel);
{
int ret;
struct lttng_evaluation_session_rotation *rotation;
- struct lttng_evaluation_session_rotation_comm comm = { 0 };
+ struct lttng_evaluation_session_rotation_comm comm = {};
rotation = container_of(evaluation,
struct lttng_evaluation_session_rotation, parent);
xmlNextElementSibling(snapshot_output_node)) {
char *name = NULL;
uint64_t max_size = UINT64_MAX;
- struct consumer_output output = { 0 };
+ struct consumer_output output = {};
struct lttng_snapshot_output *snapshot_output = NULL;
const char *control_uri = NULL;
const char *data_uri = NULL;
const struct config_load_session_override_attr *overrides)
{
int ret;
- struct consumer_output output = { 0 };
+ struct consumer_output output = {};
xmlNodePtr consumer_output_node;
const char *control_uri = NULL;
const char *data_uri = NULL;
int ret;
bool session_loaded = false;
const char *path_ptr = NULL;
- struct session_config_validation_ctx validation_ctx = { 0 };
+ struct session_config_validation_ctx validation_ctx = {};
ret = init_session_config_validation_ctx(&validation_ctx);
if (ret) {
consumer_timer_thread_get_channel_monitor_pipe();
struct lttcomm_consumer_channel_monitor_msg msg = {
.key = channel->key,
+ .lowest = 0,
+ .highest = 0,
+ .total_consumed = 0,
};
sample_positions_cb sample;
get_consumed_cb get_consumed;
{
int ret;
size_t symbol_name_len;
- struct lttng_event_probe_attr_comm comm = { 0 };
+ struct lttng_event_probe_attr_comm comm = {};
symbol_name_len = lttng_strnlen(probe->symbol_name, LTTNG_SYMBOL_NAME_LEN);
if (symbol_name_len == LTTNG_SYMBOL_NAME_LEN) {
unsigned int i;
size_t header_offset, size_before_payload;
size_t name_len;
- struct lttng_event_comm event_comm = { 0 };
+ struct lttng_event_comm event_comm = {};
struct lttng_event_comm *header;
assert(event);
struct lttng_payload *payload)
{
int ret;
- struct lttng_event_context_app_comm comm = { 0 };
+ struct lttng_event_context_app_comm comm = {};
size_t provider_len, ctx_len;
const char *provider_name;
const char *ctx_name;
struct lttng_payload *payload)
{
int ret;
- struct lttng_event_context_perf_counter_comm comm = { 0 };
+ struct lttng_event_context_perf_counter_comm comm = {};
assert(payload);
assert(context);
int ret;
size_t header_offset, size_before_event;
size_t name_len;
- struct lttng_event_field_comm event_field_comm = { 0 };
+ struct lttng_event_field_comm event_field_comm = {};
struct lttng_event_field_comm *header;
assert(field);
unsigned long value;
} seed = {
.lock = PTHREAD_MUTEX_INITIALIZER,
+ .initialized = false,
+ .value = 0,
};
static int match_fd(struct cds_lfht_node *node, const void *key);
unsigned long value;
} seed = {
.lock = PTHREAD_MUTEX_INITIALIZER,
+ .initialized = false,
+ .value = 0,
};
static unsigned long lttng_inode_id_hash(const struct inode_id *id)
* The wrapped field is set to the value it would gave if it had static storage
* duration.
*/
-#define LTTNG_OPTIONAL_INIT_UNSET { .is_set = 0 }
+#define LTTNG_OPTIONAL_INIT_UNSET {}
/*
* Initialize an optional field as 'set' with a given value.
.buffer = lttng_buffer_view_from_dynamic_buffer(
&payload->buffer, offset, len),
._fd_handles = payload->_fd_handles,
+ ._iterator = {},
} : (struct lttng_payload_view) {
.buffer = {},
- ._fd_handles = {}
+ ._fd_handles = {},
+ ._iterator = {},
};
}
._iterator = {
.p_fd_handles_position = view->_iterator.p_fd_handles_position ?:
&view->_iterator.fd_handles_position,
+ .fd_handles_position = 0,
}
} : (struct lttng_payload_view) {
.buffer = {},
- ._fd_handles = {}
+ ._fd_handles = {},
+ ._iterator = {},
};
}
return buffer ? (struct lttng_payload_view) {
.buffer = lttng_buffer_view_from_dynamic_buffer(
buffer, offset, len),
- ._fd_handles = {}
+ ._fd_handles = {},
+ ._iterator = {},
} : (struct lttng_payload_view) {
.buffer = {},
- ._fd_handles = {}
+ ._fd_handles = {},
+ ._iterator = {},
};
}
return view ? (struct lttng_payload_view) {
.buffer = lttng_buffer_view_from_view(
view, offset, len),
- ._fd_handles = {}
+ ._fd_handles = {},
+ ._iterator = {},
} : (struct lttng_payload_view) {
.buffer = {},
- ._fd_handles = {}
+ ._fd_handles = {},
+ ._iterator = {},
};
}
return (struct lttng_payload_view) {
.buffer = lttng_buffer_view_init(
src, offset, len),
- ._fd_handles = {}
+ ._fd_handles = {},
+ ._iterator = {},
};
}
.output_type = (uint8_t) descriptor->output_type,
.name_len = (uint32_t) (descriptor->name ?
strlen(descriptor->name) + 1 : 0),
- }
+ .uri_count = 0,
+ },
+ .live_timer_us = 0,
+
};
const void *header_ptr = NULL;
size_t header_size;
{
int ret = 0;
socklen_t storage_len;
- struct sockaddr_storage storage = { 0 };
+ struct sockaddr_storage storage = {};
assert(sock);
assert(fd >= 0);
enum lttng_trace_chunk_status status = LTTNG_TRACE_CHUNK_STATUS_OK;
const struct chunk_credentials credentials = {
.use_current_user = true,
+ .user = {},
};
pthread_mutex_lock(&chunk->lock);
int ret;
struct process_attr_tracker_value_comm value_comm = {
.type = (int32_t) value->type,
+ .value = {},
};
const char *name = NULL;
{ .name = "tcp4", .leading_string = "tcp4://", .code = P_TCP, .type = LTTNG_TCP, .dtype = LTTNG_DST_IPV4 },
{ .name = "tcp6", .leading_string = "tcp6://", .code = P_TCP6, .type = LTTNG_TCP, .dtype = LTTNG_DST_IPV6 },
/* Invalid proto marking the end of the array. */
- { 0 }
+ {}
};
/*
struct lttng_notification_channel_message msg_header = {
.type = LTTNG_NOTIFICATION_CHANNEL_MESSAGE_TYPE_HANDSHAKE,
.size = sizeof(handshake),
+ .fds = 0,
};
char send_buffer[sizeof(msg_header) + sizeof(handshake)];
struct lttng_payload payload;
struct lttng_notification_channel_message cmd_header = {
.type = (int8_t) type,
+ .size =0,
+ .fds = 0,
};
lttng_payload_init(&payload);
struct lttng_clear_handle *handle = NULL;
struct lttcomm_session_msg lsm = {
.cmd_type = LTTNG_CLEAR_SESSION,
+ .session = {},
+ .domain = {},
+ .u = {},
+ .fd_count = 0,
};
int sessiond_socket = -1;
ssize_t comm_ret;
enum lttng_error_code ret_code = LTTNG_OK;
struct lttcomm_session_msg lsm = {
.cmd_type = LTTNG_DESTROY_SESSION,
+ .session = {},
+ .domain = {},
+ .u = {},
+ .fd_count = 0,
};
int sessiond_socket = -1;
struct lttng_destruction_handle *handle = NULL;
const char *channel_name)
{
int ret;
- struct lttcomm_session_msg lsm = { .cmd_type = LTTNG_ADD_CONTEXT };
+ struct lttcomm_session_msg lsm = {
+ .cmd_type = LTTNG_ADD_CONTEXT,
+ .session = {},
+ .domain = {},
+ .u = {},
+ .fd_count = 0,
+ };
struct lttng_payload payload;
lttng_payload_init(&payload);
const char *original_filter_expression,
int exclusion_count, char **exclusion_list)
{
- struct lttcomm_session_msg lsm = { .cmd_type = LTTNG_ENABLE_EVENT };
+ struct lttcomm_session_msg lsm = {
+ .cmd_type = LTTNG_ENABLE_EVENT,
+ .session = {},
+ .domain = {},
+ .u = {},
+ .fd_count = 0,
+ };
struct lttng_payload payload;
int ret = 0;
unsigned int free_filter_expression = 0;
struct lttng_event *ev, const char *channel_name,
const char *original_filter_expression)
{
- struct lttcomm_session_msg lsm = { .cmd_type = LTTNG_DISABLE_EVENT };
+ struct lttcomm_session_msg lsm = {
+ .cmd_type = LTTNG_DISABLE_EVENT,
+ .session = {},
+ .domain = {},
+ .u = {},
+ .fd_count = 0,
+ };
struct lttng_payload payload;
int ret = 0;
unsigned int free_filter_expression = 0;
enum lttng_error_code ret_code;
int ret, total_payload_received;
char *reception_buffer = NULL;
- struct lttcomm_session_msg lsm = { .cmd_type = LTTNG_LIST_TRACEPOINTS };
+ struct lttcomm_session_msg lsm = {
+ .cmd_type = LTTNG_LIST_TRACEPOINTS,
+ .session = {},
+ .domain = {},
+ .u = {},
+ .fd_count = 0,
+ };
struct lttcomm_list_command_header *cmd_header = NULL;
size_t cmd_header_len;
unsigned int nb_events = 0;
enum lttng_error_code ret_code;
struct lttcomm_session_msg lsm = {
.cmd_type = LTTNG_CREATE_SESSION_EXT,
+ .session = {},
+ .domain = {},
+ .u = {},
+ .fd_count = 0,
};
void *reply = NULL;
struct lttng_buffer_view reply_view;
int ret;
struct lttcomm_session_msg lsm = {
.cmd_type = LTTNG_REGISTER_TRIGGER,
+ .session = {},
+ .domain = {},
+ .u = {},
+ .fd_count = 0,
};
lsm.u.trigger.is_trigger_anonymous = !name && !generate_name;
struct lttcomm_session_msg *message_lsm;
enum lttng_error_code ret_code;
struct lttcomm_session_msg lsm = {
.cmd_type = LTTNG_EXECUTE_ERROR_QUERY,
+ .session = {},
+ .domain = {},
+ .u = {},
+ .fd_count = 0,
};
struct lttng_payload message;
struct lttng_payload reply;
{
int ret;
enum lttng_error_code ret_code = LTTNG_OK;
- struct lttcomm_session_msg lsm = { .cmd_type = LTTNG_LIST_TRIGGERS };
+ struct lttcomm_session_msg lsm = {
+ .cmd_type = LTTNG_LIST_TRIGGERS,
+ .session = {},
+ .domain = {},
+ .u = {},
+ .fd_count = 0,
+ };
struct lttng_triggers *local_triggers = NULL;
struct lttng_payload reply;
struct lttng_payload_view lsm_view =
enum lttng_process_attr_tracker_handle_status status =
LTTNG_PROCESS_ATTR_TRACKER_HANDLE_STATUS_OK;
struct lttcomm_session_msg lsm = {
- .cmd_type = LTTNG_PROCESS_ATTR_TRACKER_GET_POLICY,
+ .cmd_type = LTTNG_PROCESS_ATTR_TRACKER_GET_POLICY,
+ .session = {},
+ .domain = {},
+ .u = {},
+ .fd_count = 0,
};
if (!tracker || !policy) {
enum lttng_process_attr_tracker_handle_status status =
LTTNG_PROCESS_ATTR_TRACKER_HANDLE_STATUS_OK;
struct lttcomm_session_msg lsm = {
- .cmd_type = LTTNG_PROCESS_ATTR_TRACKER_SET_POLICY,
+ .cmd_type = LTTNG_PROCESS_ATTR_TRACKER_SET_POLICY,
+ .session = {},
+ .domain = {},
+ .u = {},
+ .fd_count = 0,
};
if (!tracker) {
enum lttng_process_attr_tracker_handle_status status = \
LTTNG_PROCESS_ATTR_TRACKER_HANDLE_STATUS_OK; \
struct lttcomm_session_msg lsm = { \
- .cmd_type = LTTNG_PROCESS_ATTR_TRACKER_##command_upper##_INCLUDE_VALUE}; \
+ .cmd_type = LTTNG_PROCESS_ATTR_TRACKER_##command_upper##_INCLUDE_VALUE, \
+ .session = {}, \
+ .domain = {}, \
+ .u = {}, \
+ .fd_count = 0, \
+ }; \
\
if (!tracker) { \
status = LTTNG_PROCESS_ATTR_TRACKER_HANDLE_STATUS_INVALID; \
enum lttng_process_attr_tracker_handle_status status = \
LTTNG_PROCESS_ATTR_TRACKER_HANDLE_STATUS_OK; \
struct lttcomm_session_msg lsm = { \
- .cmd_type = LTTNG_PROCESS_ATTR_TRACKER_##command_upper##_INCLUDE_VALUE}; \
+ .cmd_type = LTTNG_PROCESS_ATTR_TRACKER_##command_upper##_INCLUDE_VALUE, \
+ .session = {}, \
+ .domain = {}, \
+ .u = {}, \
+ .fd_count = 0, \
+ }; \
const size_t len = value ? strlen(value) + 1 : 0; \
\
if (!tracker || !value) { \
enum lttng_process_attr_tracker_handle_status status =
LTTNG_PROCESS_ATTR_TRACKER_HANDLE_STATUS_OK;
struct lttcomm_session_msg lsm = {
- .cmd_type = LTTNG_PROCESS_ATTR_TRACKER_GET_INCLUSION_SET,
+ .cmd_type = LTTNG_PROCESS_ATTR_TRACKER_GET_INCLUSION_SET,
+ .session = {},
+ .domain = {},
+ .u = {},
+ .fd_count = 0,
};
struct lttng_buffer_view inclusion_set_view;
ssize_t inclusion_set_ret;
{
{ .run = run_working_cases, .produces_validation_info = true, .timeout = -1 },
{ .run = run_working_cases, .produces_validation_info = true, .timeout = 1 },
- { .run = pselect_invalid_fd, .produces_validation_info = false },
- { .run = test_ppoll_big, .produces_validation_info = false },
- { .run = ppoll_fds_buffer_overflow, .produces_validation_info = false },
- { .run = pselect_invalid_pointer, .produces_validation_info = false },
- { .run = ppoll_fds_ulong_max, .produces_validation_info = false },
- { .run = epoll_pwait_invalid_pointer, .produces_validation_info = true },
- { .run = epoll_pwait_int_max, .produces_validation_info = true },
- { .run = ppoll_concurrent_write, .produces_validation_info = false },
- { .run = epoll_pwait_concurrent_munmap, .produces_validation_info = true },
+ { .run = pselect_invalid_fd, .produces_validation_info = false, .timeout = 0 },
+ { .run = test_ppoll_big, .produces_validation_info = false, .timeout = 0 },
+ { .run = ppoll_fds_buffer_overflow, .produces_validation_info = false, .timeout = 0 },
+ { .run = pselect_invalid_pointer, .produces_validation_info = false, .timeout = 0 },
+ { .run = ppoll_fds_ulong_max, .produces_validation_info = false, .timeout = 0 },
+ { .run = epoll_pwait_invalid_pointer, .produces_validation_info = true, .timeout = 0 },
+ { .run = epoll_pwait_int_max, .produces_validation_info = true, .timeout = 0 },
+ { .run = ppoll_concurrent_write, .produces_validation_info = false, .timeout = 0 },
+ { .run = epoll_pwait_concurrent_munmap, .produces_validation_info = true, .timeout = 0 },
};
struct ppoll_thread_data {
{ "validation-file", 'o', POPT_ARG_STRING, &test_validation_output_file_path, 0,
"Test case output", NULL },
POPT_AUTOHELP
- { NULL, 0, 0, NULL, 0 }
+ { NULL, 0, 0, NULL, 0, NULL, NULL }
};
const struct test_case *test_case;
{
.type = LTTNG_DOMAIN_UST,
.buf_type = LTTNG_BUFFER_PER_UID,
- }
+ .padding = {},
+ .attr = {},
+ },
+ {}
};
lttng_channel channel_cfg {};
{ "test", 't', POPT_ARG_INT, &test, 0, "Test to run", NULL },
{ "list", 'l', 0, 0, 'l', "List of tests (-t X)", NULL },
POPT_AUTOHELP
- { NULL, 0, 0, NULL, 0 }
+ { NULL, 0, 0, NULL, 0, NULL, NULL }
};
optCon = poptGetContext(NULL, argc, argv, optionsTable, 0);
{ "after", 'a', POPT_ARG_STRING, &after_unshare_wait_file_path, 0, "Wait for file after unshare", NULL },
{ "signal", 's', POPT_ARG_STRING, &after_unshare_signal_file_path, 0, "Create signal file after unshare", NULL },
POPT_AUTOHELP
- { NULL, 0, 0, NULL, 0 }
+ { NULL, 0, 0, NULL, 0, NULL, NULL }
};
static ATTR_FORMAT_PRINTF(1, 2)
if HAVE_LIBLTTNG_UST_CTL
# Disable some warnings flags to accomodate the tracepoint headers
WARN_FLAGS = \
- -Wno-redundant-decls
+ -Wno-redundant-decls \
+ -Wno-missing-field-initializers
AM_CFLAGS += $(WARN_FLAGS)
AM_CXXFLAGS += $(WARN_FLAGS)
if HAVE_LIBLTTNG_UST_CTL
# Disable some warnings flags to accomodate the tracepoint headers
WARN_FLAGS = \
- -Wno-redundant-decls
+ -Wno-redundant-decls \
+ -Wno-missing-field-initializers
AM_CFLAGS += $(WARN_FLAGS)
AM_CXXFLAGS += $(WARN_FLAGS)
if HAVE_LIBLTTNG_UST_CTL
WARN_FLAGS = \
- -Wno-redundant-decls
+ -Wno-redundant-decls \
+ -Wno-missing-field-initializers
AM_CFLAGS += $(WARN_FLAGS)
AM_CXXFLAGS += $(WARN_FLAGS)
if HAVE_LIBLTTNG_UST_CTL
WARN_FLAGS = \
- -Wno-redundant-decls
+ -Wno-redundant-decls \
+ -Wno-missing-field-initializers
AM_CFLAGS += $(WARN_FLAGS)
AM_CXXFLAGS += $(WARN_FLAGS)
-I$(top_srcdir)/tests/utils/testapp
if HAVE_LIBLTTNG_UST_CTL
+AM_CXXFLAGS += \
+ -Wno-missing-field-initializers
+
noinst_PROGRAMS = gen-ust-tracef
gen_ust_tracef_SOURCES = gen-ust-tracef.cpp
gen_ust_tracef_LDADD = $(UST_LIBS) $(DL_LIBS)
int main(int argc, char **argv)
{
int ret;
- struct validation_ctx ctx = { 0 };
+ struct validation_ctx ctx = {};
/* Check if we have all argument */
if (argc < 3) {