summaryrefslogtreecommitdiffstats
path: root/generic/tclCmdIL.c
diff options
context:
space:
mode:
Diffstat (limited to 'generic/tclCmdIL.c')
-rw-r--r--generic/tclCmdIL.c12
1 files changed, 6 insertions, 6 deletions
diff --git a/generic/tclCmdIL.c b/generic/tclCmdIL.c
index ce79e20..441cf42 100644
--- a/generic/tclCmdIL.c
+++ b/generic/tclCmdIL.c
@@ -1518,16 +1518,16 @@ InfoLibraryCmd(
int objc, /* Number of arguments. */
Tcl_Obj *const objv[]) /* Argument objects. */
{
- const char *libDirName;
+ Tcl_Obj *libDirName;
if (objc != 1) {
Tcl_WrongNumArgs(interp, 1, objv, NULL);
return TCL_ERROR;
}
- libDirName = Tcl_GetVar(interp, "tcl_library", TCL_GLOBAL_ONLY);
+ libDirName = Tcl_GetVar2Ex(interp, "tcl_library", NULL, TCL_GLOBAL_ONLY);
if (libDirName != NULL) {
- Tcl_SetObjResult(interp, Tcl_NewStringObj(libDirName, -1));
+ Tcl_SetObjResult(interp, libDirName);
return TCL_OK;
}
Tcl_SetResult(interp, "no library has been specified for Tcl",TCL_STATIC);
@@ -1641,17 +1641,17 @@ InfoPatchLevelCmd(
int objc, /* Number of arguments. */
Tcl_Obj *const objv[]) /* Argument objects. */
{
- const char *patchlevel;
+ Tcl_Obj *patchlevel;
if (objc != 1) {
Tcl_WrongNumArgs(interp, 1, objv, NULL);
return TCL_ERROR;
}
- patchlevel = Tcl_GetVar(interp, "tcl_patchLevel",
+ patchlevel = Tcl_GetVar2Ex(interp, "tcl_patchLevel", NULL,
(TCL_GLOBAL_ONLY | TCL_LEAVE_ERR_MSG));
if (patchlevel != NULL) {
- Tcl_SetObjResult(interp, Tcl_NewStringObj(patchlevel, -1));
+ Tcl_SetObjResult(interp, patchlevel);
return TCL_OK;
}
return TCL_ERROR;