summaryrefslogtreecommitdiffstats
path: root/win
diff options
context:
space:
mode:
authorjan.nijtmans <nijtmans@users.sourceforge.net>2013-02-19 13:21:53 (GMT)
committerjan.nijtmans <nijtmans@users.sourceforge.net>2013-02-19 13:21:53 (GMT)
commit9279b3aad8ae6175e5238ffd10a05652a2f56c93 (patch)
tree955c6b8b15d8417069cb3dee3fec6de247795f4e /win
parent9d856256a392f919a13d4dc2171dcbdf4c39e31c (diff)
parent3eafe75fbc925da366e32a959d479a254ebfc02a (diff)
downloadtcl-9279b3aad8ae6175e5238ffd10a05652a2f56c93.zip
tcl-9279b3aad8ae6175e5238ffd10a05652a2f56c93.tar.gz
tcl-9279b3aad8ae6175e5238ffd10a05652a2f56c93.tar.bz2
Merge trunk.
Tranform Tcl_SaveResult/Tcl_RestoreResult/Tcl_DiscardResult to macros, and remove them from the stub table
Diffstat (limited to 'win')
-rw-r--r--win/tclAppInit.c10
-rw-r--r--win/tclWinDde.c3
2 files changed, 9 insertions, 4 deletions
diff --git a/win/tclAppInit.c b/win/tclAppInit.c
index 5ecebea..753eaff 100644
--- a/win/tclAppInit.c
+++ b/win/tclAppInit.c
@@ -45,7 +45,10 @@ static void setargv(int *argcPtr, TCHAR ***argvPtr);
#ifndef TCL_LOCAL_APPINIT
#define TCL_LOCAL_APPINIT Tcl_AppInit
#endif
-extern int TCL_LOCAL_APPINIT(Tcl_Interp *interp);
+#ifndef MODULE_SCOPE
+# define MODULE_SCOPE extern
+#endif
+MODULE_SCOPE int TCL_LOCAL_APPINIT(Tcl_Interp *);
/*
* The following #if block allows you to change how Tcl finds the startup
@@ -54,7 +57,7 @@ extern int TCL_LOCAL_APPINIT(Tcl_Interp *interp);
*/
#ifdef TCL_LOCAL_MAIN_HOOK
-extern int TCL_LOCAL_MAIN_HOOK(int *argc, TCHAR ***argv);
+MODULE_SCOPE int TCL_LOCAL_MAIN_HOOK(int *argc, TCHAR ***argv);
#endif
/*
@@ -193,7 +196,8 @@ Tcl_AppInit(
* specific startup file will be run under any conditions.
*/
- (Tcl_SetVar2)(interp, "tcl_rcFileName", NULL, "~/tclshrc.tcl", TCL_GLOBAL_ONLY);
+ (Tcl_ObjSetVar2)(interp, Tcl_NewStringObj("tcl_rcFileName", -1), NULL,
+ Tcl_NewStringObj("~/tclshrc.tcl", -1), TCL_GLOBAL_ONLY);
return TCL_OK;
}
diff --git a/win/tclWinDde.c b/win/tclWinDde.c
index 10876ed..05c5e2a 100644
--- a/win/tclWinDde.c
+++ b/win/tclWinDde.c
@@ -368,7 +368,8 @@ DdeSetServerName(
Tcl_DStringSetLength(&dString, offset + sizeof(TCHAR) * TCL_INTEGER_SPACE);
actualName = (TCHAR *) Tcl_DStringValue(&dString);
}
- _stprintf((TCHAR *) (Tcl_DStringValue(&dString) + offset), TEXT("%d"), suffix);
+ _sntprintf((TCHAR *) (Tcl_DStringValue(&dString) + offset),
+ TCL_INTEGER_SPACE, TEXT("%d"), suffix);
}
/*