summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorjan.nijtmans <nijtmans@users.sourceforge.net>2020-09-28 15:00:02 (GMT)
committerjan.nijtmans <nijtmans@users.sourceforge.net>2020-09-28 15:00:02 (GMT)
commit38b30033c88080b592fdbc043f295bc9b4e97b5d (patch)
tree85cfbcecd4780af8737ea1826183fb7394fdf53c
parentf6bf85fb67eb15e637ecf7c7de4f661dc0557b43 (diff)
downloadtcl-38b30033c88080b592fdbc043f295bc9b4e97b5d.zip
tcl-38b30033c88080b592fdbc043f295bc9b4e97b5d.tar.gz
tcl-38b30033c88080b592fdbc043f295bc9b4e97b5d.tar.bz2
Update internal zlib channel type from TCL_CHANNEL_VERSION_3 to TCL_CHANNEL_VERSION_5. Not actually a change, since supported procs are the same. So all internal channels have the same type
-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;