Cleanup: fix typo in relayd comment
[lttng-tools.git] / src / bin / lttng-relayd / main.c
index 09a73e392ada24798e5e1c143000f0572a253c2f..569a3a4707862c8fa1cc51c2c4ee575615c6ad8f 100644 (file)
@@ -3256,7 +3256,6 @@ static enum relay_connection_status relay_process_data_receive_header(
                DBG3("Partial reception of data connection header (received %" PRIu64 " bytes, %" PRIu64 " bytes left to receive, fd = %i)",
                                state->received, state->left_to_receive,
                                conn->sock->fd);
-               ret = 0;
                goto end;
        }
 
@@ -3323,7 +3322,6 @@ static enum relay_connection_status relay_process_data_receive_header(
                conn->protocol.data.state.receive_payload.rotate_index = true;
        }
 
-       ret = 0;
 end_stream_unlock:
        pthread_mutex_unlock(&stream->lock);
        stream_put(stream);
@@ -3426,7 +3424,7 @@ static enum relay_connection_status relay_process_data_receive_payload(
 
        ret = write_padding_to_file(stream->stream_fd->fd,
                        state->header.padding_size);
-       if (ret < 0) {
+       if ((int64_t) ret < (int64_t) state->header.padding_size) {
                ERR("write_padding_to_file: fail stream %" PRIu64 " net_seq_num %" PRIu64 " ret %d",
                                stream->stream_handle,
                                state->header.net_seq_num, ret);
@@ -3798,7 +3796,7 @@ restart:
 
 exit:
 error:
-       /* Cleanup reamaining connection object. */
+       /* Cleanup remaining connection object. */
        rcu_read_lock();
        cds_lfht_for_each_entry(relay_connections_ht->ht, &iter.iter,
                        destroy_conn,
This page took 0.023881 seconds and 4 git commands to generate.