return NULL;
}
memcpy(handle->shadow_chan, chan, chan_size);
+ /*
+ * The callback pointers in the producer are invalid in the
+ * consumer. Zero them out.
+ */
+ memset(&handle->shadow_chan->backend.config.cb, 0,
+ sizeof(handle->shadow_chan->backend.config.cb));
return handle;
}
return 0;
}
-int ustctl_flush_buffer(struct lttng_ust_shm_handle *handle,
+void ustctl_flush_buffer(struct lttng_ust_shm_handle *handle,
struct lttng_ust_lib_ring_buffer *buf,
int producer_active)
{
lib_ring_buffer_switch_slow(buf,
producer_active ? SWITCH_ACTIVE : SWITCH_FLUSH,
handle);
- return 0;
}