X-Git-Url: http://www.chiark.greenend.org.uk/ucgi/~yarrgweb/git?a=blobdiff_plain;ds=sidebyside;f=pctb%2Fcommon.h;h=9d06fabf9a55c79b8a1878a649b8db03f6aaa083;hb=b958771fa67513ba09630953ec91b9d21b3f42f9;hp=92ba2daa13d65f27cdf97fe332c48c8ee3ef5108;hpb=cfc4716fb0471f32a63072527dc4a462fe73ca99;p=ypp-sc-tools.web-live.git diff --git a/pctb/common.h b/pctb/common.h index 92ba2da..9d06fab 100644 --- a/pctb/common.h +++ b/pctb/common.h @@ -42,6 +42,7 @@ #include #include #include +#include #include @@ -52,7 +53,6 @@ typedef struct { int w,h; - const struct RgbImage *rgb; char d[]; } CanonImage; @@ -155,6 +155,11 @@ void dbfile_close(void); /* idempotent */ int dbfile_scanf(const char *fmt, ...) SCANFMT(1,2); int dbfile_vscanf(const char *fmt, va_list al) SCANFMT(1,0); +int gzopen(const char *zpath, int oflags, FILE **f_r, pid_t *pid_r, + const char *gziplevel /* 0 for read; may be 0, or "-1" etc. */); + /* returns errno value from open */ +void gzclose(FILE **f, pid_t *p, const char *what); + /* also OK with f==0, or p==-1 */ char *masprintf(const char *fmt, ...) FMT(1,2);