The
zopen()
function opens a gzip file whose name is the string pointed to by
path
and returns a stream which can be used to access the uncompressed contents
of the file.
The
zdopen()
variant takes a gzip file referenced by the file descriptor
fd,
analogous to
fdopen(3).
They are wrappers around
zlib(3)
and the standard stream I/O APIs.
The argument
mode
has the same meaning as it does in
fopen(3).
The
zopen()
and
zdopen()
functions will associate the read, write, seek and close
functions of
zlib(3)
with the returned stream.