fix: tie compaction probe build to CONFIG_COMPACTION
[lttng-modules.git] / src / lttng-abi.c
index c3e676902d787fe88c84d0ef034930f169cd4372..59fea6266a840fd53e568c6526f12a60ccb72333 100644 (file)
@@ -1016,7 +1016,7 @@ ssize_t lttng_event_notifier_group_notif_read(struct file *filp, char __user *us
 
        /* Finish copy of previous record */
        if (*ppos != 0) {
-               if (read_count < count) {
+               if (count != 0) {
                        len = chan->iter.len_left;
                        read_offset = *ppos;
                        goto skip_get_next;
@@ -1096,7 +1096,8 @@ nodata:
        chan->iter.len_left = 0;
 
 put_record:
-       lib_ring_buffer_put_current_record(buf);
+       if (*ppos == 0)
+               lib_ring_buffer_put_current_record(buf);
        return read_count;
 }
 
This page took 0.024296 seconds and 4 git commands to generate.