Fix: pass proper args when writing commit counter
[lttng-ust.git] / libringbuffer / frontend_internal.h
index 8a0f78f32ee774e19e853b3c7c511957ed7adb85..51b652d2a3d2ed5dbb9eb41d0942a522bd4c86a7 100644 (file)
@@ -499,23 +499,20 @@ void lib_ring_buffer_write_commit_counter(const struct lttng_ust_lib_ring_buffer
                                          unsigned long idx,
                                          unsigned long buf_offset,
                                          unsigned long commit_count,
-                                         size_t slot_size,
                                          struct lttng_ust_shm_handle *handle)
 {
-       unsigned long offset, commit_seq_old;
+       unsigned long commit_seq_old;
 
        if (config->oops != RING_BUFFER_OOPS_CONSISTENCY)
                return;
 
-       offset = buf_offset + slot_size;
-
        /*
         * subbuf_offset includes commit_count_mask. We can simply
         * compare the offsets within the subbuffer without caring about
         * buffer full/empty mismatch because offset is never zero here
         * (subbuffer header and record headers have non-zero length).
         */
-       if (caa_unlikely(subbuf_offset(offset - commit_count, chan)))
+       if (caa_unlikely(subbuf_offset(buf_offset - commit_count, chan)))
                return;
 
        commit_seq_old = v_read(config, &shmp_index(handle, buf->commit_hot, idx)->seq);
This page took 0.023844 seconds and 4 git commands to generate.