1ZIP_SOURCE_WINDOW(3)     BSD Library Functions Manual     ZIP_SOURCE_WINDOW(3)
2

NAME

4     zip_source_window_create — create zip data source overlay
5

LIBRARY

7     libzip (-lzip)
8

SYNOPSIS

10     #include <zip.h>
11
12     zip_source_t *
13     zip_source_window_create(zip_source_t *source, zip_uint64_t start,
14         zip_int64_t len, zip_error_t *error);
15

DESCRIPTION

17     The zip_source_window_create() function create a zip source from an un‐
18     derlying zip source, restricting access to a particular window starting
19     at byte start and having size len.  If len is -1, the window spans to the
20     end of the underlying source.
21

RETURN VALUES

23     Upon successful completion, the created source is returned.  Otherwise,
24     NULL is returned and the error code in error is set to indicate the er‐
25     ror.
26

ERRORS

28     zip_source_window_create() fails if:
29
30     [ZIP_ER_INVAL]     src is NULL; there is an integer overflow adding start
31                        and len; or len is less than -1.
32
33     [ZIP_ER_MEMORY]    Required memory could not be allocated.
34

SEE ALSO

36     libzip(3), zip_source(3) zip_source(3)
37

HISTORY

39     zip_source_window_create() was added in libzip 1.8.0.
40

AUTHORS

42     Dieter Baron <dillo@nih.at> and Thomas Klausner <tk@giga.or.at>
43
44BSD                             April 29, 2021                             BSD
Impressum