summaryrefslogtreecommitdiffstats
path: root/generic/tclZlib.c
diff options
context:
space:
mode:
authordkf <donal.k.fellows@manchester.ac.uk>2012-03-31 13:48:11 (GMT)
committerdkf <donal.k.fellows@manchester.ac.uk>2012-03-31 13:48:11 (GMT)
commitfa08af34c6ae5907fc9a6f4c20182dd11ba28f45 (patch)
tree42924b8cb10e56c26438c69ad96dc12c0b84be2e /generic/tclZlib.c
parent258e927279e1a28d29a07a1c07ebee9a99890e69 (diff)
downloadtcl-fa08af34c6ae5907fc9a6f4c20182dd11ba28f45.zip
tcl-fa08af34c6ae5907fc9a6f4c20182dd11ba28f45.tar.gz
tcl-fa08af34c6ae5907fc9a6f4c20182dd11ba28f45.tar.bz2
Start of implementation of TIP 400: zlib improvements
Diffstat (limited to 'generic/tclZlib.c')
-rw-r--r--generic/tclZlib.c23
1 files changed, 22 insertions, 1 deletions
diff --git a/generic/tclZlib.c b/generic/tclZlib.c
index 81012dc..6f82e06 100644
--- a/generic/tclZlib.c
+++ b/generic/tclZlib.c
@@ -864,7 +864,7 @@ Tcl_ZlibStreamEof(
*/
int
-Tcl_ZlibStreamChecksum(
+Tcl_ZlibStreamGetZstreamp(
Tcl_ZlibStream zshandle) /* As obtained from Tcl_ZlibStreamInit */
{
ZlibStreamHandle *zshPtr = (ZlibStreamHandle *) zshandle;
@@ -875,6 +875,27 @@ Tcl_ZlibStreamChecksum(
/*
*----------------------------------------------------------------------
*
+ * Tcl_ZlibStreamGetZstreamp --
+ *
+ * Return the z_streamp for the stream (though not typed as such, so as
+ * to avoid type interface poisoning). Shouldn't be used to poke around
+ * excessively.
+ *
+ *----------------------------------------------------------------------
+ */
+
+void *
+Tcl_ZlibStreamGetZstreamp(
+ Tcl_ZlibStream zshandle)
+{
+ ZlibStreamHandle *zshPtr = (ZlibStreamHandle *) zshandle;
+
+ return &zshPtr->stream;
+}
+
+/*
+ *----------------------------------------------------------------------
+ *
* Tcl_ZlibStreamPut --
*
* Add data to the stream for compression or decompression from a