struct lttng_ht_iter iter;
struct relay_stream *stream = nullptr;
- lttng::urcu::read_lock_guard read_lock;
+ const lttng::urcu::read_lock_guard read_lock;
lttng_ht_lookup(relay_streams_ht, &stream_id, &iter);
node = lttng_ht_iter_get_node<lttng_ht_node_u64>(&iter);
if (!node) {
*/
static int try_rotate_stream_index(struct relay_stream *stream)
{
- int ret = 0;
+ const int ret = 0;
if (!stream->ongoing_rotation.is_set) {
/* No rotation expected. */
void stream_put(struct relay_stream *stream)
{
- lttng::urcu::read_lock_guard read_lock;
+ const lttng::urcu::read_lock_guard read_lock;
LTTNG_ASSERT(stream->ref.refcount != 0);
/*
* Wait until we have processed all the stream packets before
struct relay_index *index;
{
- lttng::urcu::read_lock_guard read_lock;
+ const lttng::urcu::read_lock_guard read_lock;
cds_lfht_for_each_entry (stream->indexes_ht->ht, &iter.iter, index, index_n.node) {
DBG("index %p net_seq_num %" PRIu64 " refcount %ld"
}
{
- lttng::urcu::read_lock_guard read_lock;
+ const lttng::urcu::read_lock_guard read_lock;
cds_lfht_for_each_entry (relay_streams_ht->ht, &iter.iter, stream, node.node) {
if (!stream_get(stream)) {