summaryrefslogtreecommitdiffstats
path: root/win/tclWinInit.c
diff options
context:
space:
mode:
authordgp <dgp@users.sourceforge.net>2004-12-04 21:19:15 (GMT)
committerdgp <dgp@users.sourceforge.net>2004-12-04 21:19:15 (GMT)
commit199c1fb12767c9ef58c43b56f33ca3113eb738ab (patch)
tree545a48ddf28d3b44bd1730534af8f674aa8e06b3 /win/tclWinInit.c
parent2eb6dbf5b27a10b106d4ed4774b053de32876cf6 (diff)
downloadtcl-199c1fb12767c9ef58c43b56f33ca3113eb738ab.zip
tcl-199c1fb12767c9ef58c43b56f33ca3113eb738ab.tar.gz
tcl-199c1fb12767c9ef58c43b56f33ca3113eb738ab.tar.bz2
* generic/tclEncoding.c: Different fix for [Bug 1077005].
* generic/tclEvent.c: Broke apart TclpSetInitialEncodings() on * generic/tclInt.h: Windows into TclpSetInterfaces(), that is * unix/tclUnixInit.c: fundamentally essential, and the initialization * win/tclWinInit.c: of the system encoding, which is not. Made the TclpSetInterfaces call part of TclInitSubsystems so it cannot be overlooked.
Diffstat (limited to 'win/tclWinInit.c')
-rw-r--r--win/tclWinInit.c17
1 files changed, 11 insertions, 6 deletions
diff --git a/win/tclWinInit.c b/win/tclWinInit.c
index 0b54cdb..d8d4fc9 100644
--- a/win/tclWinInit.c
+++ b/win/tclWinInit.c
@@ -7,7 +7,7 @@
* Copyright (c) 1998-1999 by Scriptics Corporation.
* All rights reserved.
*
- * RCS: @(#) $Id: tclWinInit.c,v 1.64 2004/11/30 19:34:52 dgp Exp $
+ * RCS: @(#) $Id: tclWinInit.c,v 1.65 2004/12/04 21:19:19 dgp Exp $
*/
#include "tclWinInt.h"
@@ -441,17 +441,22 @@ TclWinEncodingsCleanup()
void
TclpSetInitialEncodings()
{
- int platformId, useWide;
Tcl_DString encodingName;
+
+ TclpSetInterfaces();
+ Tcl_SetSystemEncoding(NULL,
+ TclpGetEncodingNameFromEnvironment(&encodingName));
+ Tcl_DStringFree(&encodingName);
+}
+void
+TclpSetInterfaces()
+{
+ int platformId, useWide;
platformId = TclWinGetPlatformId();
useWide = ((platformId == VER_PLATFORM_WIN32_NT)
|| (platformId == VER_PLATFORM_WIN32_CE));
TclWinSetInterfaces(useWide);
-
- Tcl_SetSystemEncoding(NULL,
- TclpGetEncodingNameFromEnvironment(&encodingName));
- Tcl_DStringFree(&encodingName);
}
CONST char *