unofficial mirror of notmuch@notmuchmail.org
 help / color / mirror / code / Atom feed
blob 296dc91441be04e0c32fbacd7938819750930c9b 857 bytes (raw)
name: util/zlib-extra.h 	 # note: path name is non-authoritative(*)

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
 
#ifndef _ZLIB_EXTRA_H
#define _ZLIB_EXTRA_H

#include "util.h"
#include <zlib.h>

#ifdef __cplusplus
extern "C" {
#endif

/* Like getline, but read from a gzFile. Allocation is with talloc.
 * Returns:
 *
 *   UTIL_SUCCESS, UTIL_OUT_OF_MEMORY, UTIL_ERRNO, UTIL_GZERROR
 *			Consult util.h for description
 *
 *   UTIL_EOF		End of file encountered before
 *			any characters read
 */
util_status_t
gz_getline (void *ctx, char **lineptr, ssize_t *bytes_read, gzFile stream);

/* return a suitable error string based on the return status
 *  from gz_readline
 */

const char *
gz_error_string (util_status_t status, gzFile stream);

/* Call gzerror with a dummy errno argument, the docs don't promise to
 * support the NULL case */
inline const char *
gzerror_str(gzFile file) { int dummy; return gzerror (file, &dummy); }

#ifdef __cplusplus
}
#endif

#endif

debug log:

solving 296dc914 ...
found 296dc914 in https://yhetil.org/notmuch.git/

(*) Git path names are given by the tree(s) the blob belongs to.
    Blobs themselves have no identifier aside from the hash of its contents.^

Code repositories for project(s) associated with this public inbox

	https://yhetil.org/notmuch.git/

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).