end:
return ret;
error:
- lttng_dynamic_buffer_set_size(&channel->reception_buffer, 0);
+ if (lttng_dynamic_buffer_set_size(&channel->reception_buffer, 0)) {
+ ret = -1;
+ }
goto end;
}
pthread_mutex_lock(&channel->lock);
- ret = lttcomm_send_unix_sock(channel->socket, send_buffer,
+ ret = lttcomm_send_creds_unix_sock(channel->socket, send_buffer,
sizeof(send_buffer));
if (ret < 0) {
goto end_unlock;