From: David Goulet Date: Fri, 28 Jun 2013 18:16:15 +0000 (-0400) Subject: Fix: use snapshot consumer output for kernel X-Git-Tag: v2.3.0-rc1~91 X-Git-Url: https://git.lttng.org/?p=lttng-tools.git;a=commitdiff_plain;h=5eecee74ccdce343ccf1504174eef7c03d859fb0 Fix: use snapshot consumer output for kernel Signed-off-by: David Goulet --- diff --git a/src/bin/lttng-sessiond/cmd.c b/src/bin/lttng-sessiond/cmd.c index c783e82f0..ed4d6c86f 100644 --- a/src/bin/lttng-sessiond/cmd.c +++ b/src/bin/lttng-sessiond/cmd.c @@ -2374,8 +2374,8 @@ static int set_relayd_for_snapshot(struct consumer_output *consumer, * snapshot output. */ rcu_read_lock(); - cds_lfht_for_each_entry(consumer->socks->ht, &iter.iter, socket, - node.node) { + cds_lfht_for_each_entry(snap_output->consumer->socks->ht, &iter.iter, + socket, node.node) { ret = send_consumer_relayd_sockets(0, session->id, snap_output->consumer, socket); if (ret < 0) { diff --git a/src/bin/lttng-sessiond/snapshot.c b/src/bin/lttng-sessiond/snapshot.c index ba7cdff2c..5265cf557 100644 --- a/src/bin/lttng-sessiond/snapshot.c +++ b/src/bin/lttng-sessiond/snapshot.c @@ -49,6 +49,9 @@ int snapshot_output_init(uint64_t max_size, const char *name, assert(output); + DBG2("Snapshot output initializing with max size %" PRIu64 ", name %s " + "ctrl URL %s, data URL %s", max_size, name, ctrl_url, data_url); + output->max_size = max_size; if (snapshot) { output->id = get_next_output_id(snapshot); diff --git a/src/common/kernel-consumer/kernel-consumer.c b/src/common/kernel-consumer/kernel-consumer.c index 5b05d9f6b..a0818452f 100644 --- a/src/common/kernel-consumer/kernel-consumer.c +++ b/src/common/kernel-consumer/kernel-consumer.c @@ -664,9 +664,9 @@ int lttng_kconsumer_recv_cmd(struct lttng_consumer_local_data *ctx, /* Do not monitor this stream. */ if (!channel->monitor) { - DBG("Kernel consumer add stream %s in no monitor mode with" + DBG("Kernel consumer add stream %s in no monitor mode with " "relayd id %" PRIu64, new_stream->name, - new_stream->relayd_stream_id); + new_stream->net_seq_idx); cds_list_add(&new_stream->no_monitor_node, &channel->stream_no_monitor_list.head); break;