Restore gzgetc function for binary compatibility.
Newly compiled applications will use the gzgetc macro.
This commit is contained in:
12
gzread.c
12
gzread.c
@@ -390,10 +390,7 @@ int ZEXPORT gzgetc_(file)
|
||||
(state->err != Z_OK && state->err != Z_BUF_ERROR))
|
||||
return -1;
|
||||
|
||||
/* try output buffer (no need to check for skip request) -- while
|
||||
this check really isn't required since the gzgetc() macro has
|
||||
already determined that x.have is zero, we leave it in for
|
||||
completeness. */
|
||||
/* try output buffer (no need to check for skip request) */
|
||||
if (state->x.have) {
|
||||
state->x.have--;
|
||||
state->x.pos++;
|
||||
@@ -405,6 +402,13 @@ int ZEXPORT gzgetc_(file)
|
||||
return ret < 1 ? -1 : buf[0];
|
||||
}
|
||||
|
||||
#undef gzgetc
|
||||
int ZEXPORT gzgetc(file)
|
||||
gzFile file;
|
||||
{
|
||||
return gzgetc_(file);
|
||||
}
|
||||
|
||||
/* -- see zlib.h -- */
|
||||
int ZEXPORT gzungetc(c, file)
|
||||
int c;
|
||||
|
||||
Reference in New Issue
Block a user