Fix: posix_fallocate() returns int > 0 on errors
[babeltrace.git] / formats / ctf / ctf.c
index 29fa5984a110b8421287308bb1c3a4998fe1a4ce..a32e0cc03d819f5886ef49ffe171ac95f15a5587 100644 (file)
@@ -908,7 +908,7 @@ void ctf_packet_seek(struct bt_stream_pos *stream_pos, size_t index, int whence)
                pos->packet_size = WRITE_PACKET_LEN;
                off = posix_fallocate(pos->fd, pos->mmap_offset,
                                      pos->packet_size / CHAR_BIT);
-               assert(off >= 0);
+               assert(off == 0);
                pos->offset = 0;
        } else {
        read_next_packet:
This page took 0.022924 seconds and 4 git commands to generate.