summaryrefslogtreecommitdiffstats
path: root/generic/tclZlib.c
diff options
context:
space:
mode:
authordgp <dgp@users.sourceforge.net>2013-03-27 18:48:07 (GMT)
committerdgp <dgp@users.sourceforge.net>2013-03-27 18:48:07 (GMT)
commit3105dcac7e1070aadd5e3d56d75abe20db80a20e (patch)
tree1ea8708b5841b141d11446582517c28e22d45de4 /generic/tclZlib.c
parent79ad7f2edc9a935417a82892dd40a70c828f51a1 (diff)
downloadtcl-3105dcac7e1070aadd5e3d56d75abe20db80a20e.zip
tcl-3105dcac7e1070aadd5e3d56d75abe20db80a20e.tar.gz
tcl-3105dcac7e1070aadd5e3d56d75abe20db80a20e.tar.bz2
Tolerate NULL interps
Diffstat (limited to 'generic/tclZlib.c')
-rw-r--r--generic/tclZlib.c18
1 files changed, 12 insertions, 6 deletions
diff --git a/generic/tclZlib.c b/generic/tclZlib.c
index ff887c8..9bceb4c 100644
--- a/generic/tclZlib.c
+++ b/generic/tclZlib.c
@@ -3891,8 +3891,10 @@ Tcl_ZlibStreamInit(
Tcl_Obj *dictObj,
Tcl_ZlibStream *zshandle)
{
- Tcl_SetObjResult(interp, Tcl_NewStringObj("unimplemented", -1));
- Tcl_SetErrorCode(interp, "TCL", "UNIMPLEMENTED", NULL);
+ if (interp) {
+ Tcl_SetObjResult(interp, Tcl_NewStringObj("unimplemented", -1));
+ Tcl_SetErrorCode(interp, "TCL", "UNIMPLEMENTED", NULL);
+ }
return TCL_ERROR;
}
@@ -3957,8 +3959,10 @@ Tcl_ZlibDeflate(
int level,
Tcl_Obj *gzipHeaderDictObj)
{
- Tcl_SetObjResult(interp, Tcl_NewStringObj("unimplemented", -1));
- Tcl_SetErrorCode(interp, "TCL", "UNIMPLEMENTED", NULL);
+ if (interp) {
+ Tcl_SetObjResult(interp, Tcl_NewStringObj("unimplemented", -1));
+ Tcl_SetErrorCode(interp, "TCL", "UNIMPLEMENTED", NULL);
+ }
return TCL_ERROR;
}
@@ -3970,8 +3974,10 @@ Tcl_ZlibInflate(
int bufferSize,
Tcl_Obj *gzipHeaderDictObj)
{
- Tcl_SetObjResult(interp, Tcl_NewStringObj("unimplemented", -1));
- Tcl_SetErrorCode(interp, "TCL", "UNIMPLEMENTED", NULL);
+ if (interp) {
+ Tcl_SetObjResult(interp, Tcl_NewStringObj("unimplemented", -1));
+ Tcl_SetErrorCode(interp, "TCL", "UNIMPLEMENTED", NULL);
+ }
return TCL_ERROR;
}