summaryrefslogtreecommitdiffstats
path: root/generic/tclOOInfo.c
diff options
context:
space:
mode:
authordgp <dgp@users.sourceforge.net>2018-11-16 20:44:08 (GMT)
committerdgp <dgp@users.sourceforge.net>2018-11-16 20:44:08 (GMT)
commitf1dbfbf21581370d5dad9cbeb4c8ac09f93fb30c (patch)
tree23939403aac62529ec29568c072731b9b2a25e6f /generic/tclOOInfo.c
parentd904246bf4e9a50662c96fd30a010175aba29ab1 (diff)
parent1fae54c8c004d072d62e3d867ef4e66b238d0bcd (diff)
downloadtcl-f1dbfbf21581370d5dad9cbeb4c8ac09f93fb30c.zip
tcl-f1dbfbf21581370d5dad9cbeb4c8ac09f93fb30c.tar.gz
tcl-f1dbfbf21581370d5dad9cbeb4c8ac09f93fb30c.tar.bz2
merge 8.7
Diffstat (limited to 'generic/tclOOInfo.c')
-rw-r--r--generic/tclOOInfo.c14
1 files changed, 8 insertions, 6 deletions
diff --git a/generic/tclOOInfo.c b/generic/tclOOInfo.c
index 9b9f490..faf3676 100644
--- a/generic/tclOOInfo.c
+++ b/generic/tclOOInfo.c
@@ -118,12 +118,14 @@ TclOOInitInfo(
*/
infoCmd = Tcl_FindCommand(interp, "info", NULL, TCL_GLOBAL_ONLY);
- Tcl_GetEnsembleMappingDict(NULL, infoCmd, &mapDict);
- Tcl_DictObjPut(NULL, mapDict, Tcl_NewStringObj("object", -1),
- Tcl_NewStringObj("::oo::InfoObject", -1));
- Tcl_DictObjPut(NULL, mapDict, Tcl_NewStringObj("class", -1),
- Tcl_NewStringObj("::oo::InfoClass", -1));
- Tcl_SetEnsembleMappingDict(interp, infoCmd, mapDict);
+ if (infoCmd) {
+ Tcl_GetEnsembleMappingDict(NULL, infoCmd, &mapDict);
+ Tcl_DictObjPut(NULL, mapDict, Tcl_NewStringObj("object", -1),
+ Tcl_NewStringObj("::oo::InfoObject", -1));
+ Tcl_DictObjPut(NULL, mapDict, Tcl_NewStringObj("class", -1),
+ Tcl_NewStringObj("::oo::InfoClass", -1));
+ Tcl_SetEnsembleMappingDict(interp, infoCmd, mapDict);
+ }
}
/*