On 12/31/2009 03:01 AM, malc wrote:
>        lseek(fd, header_size, SEEK_SET);

Surprising that lseek's return value is not marked warn_unused_result.

Probably because it's guaranteed not to fail because of I/O errors:

ERRORS
       EBADF  fd is not an open file descriptor.

       EINVAL whence is not  one  of  SEEK_SET,  SEEK_CUR,  SEEK_END;
              or the resulting file offset would be negative, or
              beyond the end of a seekable device.

       EOVERFLOW
              The resulting file offset cannot be represented in an
              off_t.

       ESPIPE fd is associated with a pipe, socket, or FIFO.



Reply via email to