Fix: posix_fallocate() returns int > 0 on errors
[babeltrace.git] / formats / ctf / ctf.c
index 74fcb5bc60fe316cf45e6926ae047a15aedd0ddf..19f61b580ef6318b555fc3885defafc3be337bc5 100644 (file)
@@ -906,7 +906,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.023318 seconds and 4 git commands to generate.