zlib functions.