* uses its own credentials for the stream files.
*/
ret = utils_create_stream_file(stream->path_name, stream->channel_name,
- stream->tracefile_size, 0, -1, -1);
+ stream->tracefile_size, 0, -1, -1, NULL);
if (ret < 0) {
ERR("Create output file");
goto end;
goto end;
}
- ret = sscanf(VERSION, "%10u.%10u", &reply.major, &reply.minor);
- if (ret < 2) {
- ERR("Error in scanning version");
- ret = -1;
- goto end;
- }
+ reply.major = RELAYD_VERSION_COMM_MAJOR;
+ reply.minor = RELAYD_VERSION_COMM_MINOR;
/* Major versions must be the same */
if (reply.major != be32toh(msg.major)) {
ret = utils_rotate_stream_file(stream->path_name,
stream->channel_name, stream->tracefile_size,
stream->tracefile_count, -1, -1,
- stream->fd, &(stream->tracefile_count_current));
+ stream->fd, &(stream->tracefile_count_current),
+ &stream->fd);
if (ret < 0) {
ERR("Rotating output file");
goto end;
/* Set up max poll set size */
lttng_poll_set_max_size();
+ /* Initialize communication library */
+ lttcomm_init();
+
/* Setup the dispatcher thread */
ret = pthread_create(&dispatcher_thread, NULL,
relay_thread_dispatcher, (void *) NULL);