1ZIP_SOURCE_READ(3) BSD Library Functions Manual ZIP_SOURCE_READ(3)
2
4 zip_source_read — read data from zip source
5
7 libzip (-lzip)
8
10 #include <zip.h>
11
12 zip_int64_t
13 zip_source_read(zip_source_t *source, void *data, zip_uint64_t len);
14
16 The function zip_source_read() reads up to len bytes of data from source
17 at the current read offset into the buffer data.
18
19 The zip source source has to be opened for reading by calling
20 zip_source_open(3) first.
21
23 Upon successful completion the number of bytes read is returned. When
24 zip_source_read() is called after reaching the end of the file, 0 is re‐
25 turned. Otherwise, -1 is returned and the error information in source is
26 set to indicate the error.
27
29 libzip(3), zip_source(3), zip_source_seek(3), zip_source_tell(3),
30 zip_source_write(3)
31
33 zip_source_read() was added in libzip 1.0.
34
36 Dieter Baron <dillo@nih.at> and Thomas Klausner <tk@giga.or.at>
37
38BSD September 28, 2021 BSD