summaryrefslogtreecommitdiffstats
path: root/generic/tclMain.c
diff options
context:
space:
mode:
authorjan.nijtmans <nijtmans@users.sourceforge.net>2012-12-04 15:12:12 (GMT)
committerjan.nijtmans <nijtmans@users.sourceforge.net>2012-12-04 15:12:12 (GMT)
commit19d35f4ef53660720d360042a30f3d9dafd5e5be (patch)
tree67fa2f16a142415270d6e1682f46288b6310666f /generic/tclMain.c
parent279358fa3f6fd886a5cf940ea9223c5a51d6f304 (diff)
downloadtcl-19d35f4ef53660720d360042a30f3d9dafd5e5be.zip
tcl-19d35f4ef53660720d360042a30f3d9dafd5e5be.tar.gz
tcl-19d35f4ef53660720d360042a30f3d9dafd5e5be.tar.bz2
more eliminations of 'deprecated' calls
Diffstat (limited to 'generic/tclMain.c')
-rw-r--r--generic/tclMain.c10
1 files changed, 5 insertions, 5 deletions
diff --git a/generic/tclMain.c b/generic/tclMain.c
index 5736881..e422806 100644
--- a/generic/tclMain.c
+++ b/generic/tclMain.c
@@ -270,16 +270,16 @@ Tcl_SourceRCFile(
Tcl_Interp *interp) /* Interpreter to source rc file into. */
{
Tcl_DString temp;
- CONST char *fileName;
+ Tcl_Obj *fileName;
Tcl_Channel chan;
- fileName = Tcl_GetVar2(interp, "tcl_rcFileName", NULL, TCL_GLOBAL_ONLY);
+ fileName = Tcl_GetVar2Ex(interp, "tcl_rcFileName", NULL, TCL_GLOBAL_ONLY);
if (fileName != NULL) {
Tcl_Channel c;
CONST char *fullName;
Tcl_DStringInit(&temp);
- fullName = Tcl_TranslateFileName(interp, fileName, &temp);
+ fullName = Tcl_TranslateFileName(interp, Tcl_GetString(fileName), &temp);
if (fullName == NULL) {
/*
* Couldn't translate the file name (e.g. it referred to a bogus
@@ -387,7 +387,7 @@ Tcl_Main(
path = Tcl_NewStringObj(Tcl_DStringValue(&appName), -1);
Tcl_SetStartupScript(path, encodingName);
}
- Tcl_SetVar(interp, "argv0", Tcl_DStringValue(&appName), TCL_GLOBAL_ONLY);
+ Tcl_SetVar2Ex(interp, "argv0", NULL, Tcl_NewStringObj(Tcl_DStringValue(&appName), -1), TCL_GLOBAL_ONLY);
Tcl_DStringFree(&appName);
argc--;
argv++;
@@ -409,7 +409,7 @@ Tcl_Main(
*/
tty = isatty(0);
- Tcl_SetVar(interp, "tcl_interactive", ((path == NULL) && tty) ? "1" : "0",
+ Tcl_SetVar2Ex(interp, "tcl_interactive", NULL, Tcl_NewIntObj((path == NULL) && tty),
TCL_GLOBAL_ONLY);
/*