Skip site navigation (1)Skip section navigation (2)

FreeBSD Manual Pages

  
 
  

home | help
ZIP_SOURCE_SEEK_COMPU... BSD Library Functions Manual ZIP_SOURCE_SEEK_COMPU...

NAME
     zip_source_seek_compute_offset -- validate	arguments and compute offset

LIBRARY
     libzip (-lzip)

SYNOPSIS
     #include <zip.h>

     zip_int64_t
     zip_source_seek_compute_offset(zip_uint64_t offset, zip_uint64_t length,
	 void *data, zip_uint64_t data_length, zip_error_t *error);

DESCRIPTION
     Use this function to compute the offset for a ZIP_SOURCE_SEEK or
     ZIP_SOURCE_SEEK_WRITE command.  data and data_length are the arguments to
     the source	callback, offset is the	current	offset and length is the
     length of the source data or, for ZIP_SOURCE_SEEK_WRITE, the amount of
     data written.

RETURN VALUES
     On	success, it returns the	new offset, on error it	returns	-1 and sets
     error.

ERRORS
     zip_source_seek_compute_offset() fails if:

     [ZIP_ER_INVAL]	One of the arguments is	invalid	or the seek would
			place the offset outside the data.

SEE ALSO
     zip_source_function(3)

AUTHORS
     Dieter Baron <dillo@nih.at> and Thomas Klausner <tk@giga.or.at>

BSD			       November	13, 2014			   BSD

NAME | LIBRARY | SYNOPSIS | DESCRIPTION | RETURN VALUES | ERRORS | SEE ALSO | AUTHORS

Want to link to this manual page? Use this URL:
<https://www.freebsd.org/cgi/man.cgi?query=zip_source_seek_compute_offset&sektion=3&manpath=FreeBSD+12.0-RELEASE+and+Ports>

home | help