lseek ¶POSIX specification:
https://pubs.opengroup.org/onlinepubs/9799919799/functions/lseek.html
Portability problems fixed by Gnulib:
lseek (fd, offset, SEEK_DATA) returns a value
greater than offset even when offset addresses data:
macOS 14.
<io.h>)
on some platforms:
MSVC 14.
off_t is a 32-bit type, lseek does not work
correctly with files 2 GiB and larger. See Large File Support.
Portability problems not fixed by Gnulib:
SEEK_DATA and SEEK_HOLE:
AIX, HP-UX, Microsoft Windows, NetBSD, OpenBSD, Cygwin 3.4.6.
SEEK_DATA and SEEK_HOLE,
and Gnulib works around the problem via #undef SEEK_DATA
and #undef SEEK_HOLE:
FreeBSD 13, macOS 12.