summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--generic/tclZlib.c16
1 files changed, 8 insertions, 8 deletions
diff --git a/generic/tclZlib.c b/generic/tclZlib.c
index 604ce64..bdda9bc 100644
--- a/generic/tclZlib.c
+++ b/generic/tclZlib.c
@@ -205,7 +205,7 @@ static void ZlibTransformTimerRun(ClientData clientData);
static const Tcl_ChannelType zlibChannelType = {
"zlib",
- TCL_CHANNEL_VERSION_3,
+ TCL_CHANNEL_VERSION_5,
ZlibTransformClose,
ZlibTransformInput,
ZlibTransformOutput,
@@ -2664,21 +2664,21 @@ ZlibStreamAddCmd(
switch ((enum addOptions) index) {
case ao_flush: /* -flush */
- if (flush > -1) {
+ if (flush >= 0) {
flush = -2;
} else {
flush = Z_SYNC_FLUSH;
}
break;
case ao_fullflush: /* -fullflush */
- if (flush > -1) {
+ if (flush >= 0) {
flush = -2;
} else {
flush = Z_FULL_FLUSH;
}
break;
case ao_finalize: /* -finalize */
- if (flush > -1) {
+ if (flush >= 0) {
flush = -2;
} else {
flush = Z_FINISH;
@@ -2788,21 +2788,21 @@ ZlibStreamPutCmd(
switch ((enum putOptions) index) {
case po_flush: /* -flush */
- if (flush > -1) {
+ if (flush >= 0) {
flush = -2;
} else {
flush = Z_SYNC_FLUSH;
}
break;
case po_fullflush: /* -fullflush */
- if (flush > -1) {
+ if (flush >= 0) {
flush = -2;
} else {
flush = Z_FULL_FLUSH;
}
break;
case po_finalize: /* -finalize */
- if (flush > -1) {
+ if (flush >= 0) {
flush = -2;
} else {
flush = Z_FINISH;
@@ -3683,7 +3683,7 @@ ZlibStackChannelTransform(
if (cd->inAllocated < cd->readAheadLimit) {
cd->inAllocated = cd->readAheadLimit;
}
- cd->inBuffer = ckalloc(cd->inAllocated);
+ cd->inBuffer = (char *)ckalloc(cd->inAllocated);
if (cd->flags & IN_HEADER) {
if (inflateGetHeader(&cd->inStream, &cd->inHeader.header) != Z_OK) {
goto error;