X-Git-Url: https://git.lttng.org/?p=lttng-tools.git;a=blobdiff_plain;f=src%2Fbin%2Flttng-relayd%2Fstream.c;h=043d19612ce0489efffad2b1f99fc1c8be52e98d;hp=d11e436a9587019c54920841013fb9fad249088c;hb=3a735fa767e8cd922c638a25e93876e37f7f66b1;hpb=334dfcb7fdb6c4fabb16eea4fb25cf344c063579;ds=sidebyside diff --git a/src/bin/lttng-relayd/stream.c b/src/bin/lttng-relayd/stream.c index d11e436a9..043d19612 100644 --- a/src/bin/lttng-relayd/stream.c +++ b/src/bin/lttng-relayd/stream.c @@ -383,6 +383,7 @@ static int create_index_file(struct relay_stream *stream, int ret; uint32_t major, minor; char *index_subpath = NULL; + enum lttng_trace_chunk_status status; ASSERT_LOCKED(stream->lock); @@ -404,10 +405,11 @@ static int create_index_file(struct relay_stream *stream, goto end; } - ret = lttng_trace_chunk_create_subdirectory(chunk, + status = lttng_trace_chunk_create_subdirectory(chunk, index_subpath); free(index_subpath); - if (ret) { + if (status != LTTNG_TRACE_CHUNK_STATUS_OK) { + ret = -1; goto end; } stream->index_file = lttng_index_file_create_from_trace_chunk(