summaryrefslogtreecommitdiffstats
path: root/win/tclWinInit.c
diff options
context:
space:
mode:
authordgp <dgp@users.sourceforge.net>2006-04-05 16:32:39 (GMT)
committerdgp <dgp@users.sourceforge.net>2006-04-05 16:32:39 (GMT)
commit50d05904e2652689f8352c49ba3ea9b256922bb0 (patch)
tree6f98b5676e330825d6971d1bfb90ced3019e59dd /win/tclWinInit.c
parent1aa54c04958fb5a081acbd1440314021b21ca394 (diff)
downloadtcl-50d05904e2652689f8352c49ba3ea9b256922bb0.zip
tcl-50d05904e2652689f8352c49ba3ea9b256922bb0.tar.gz
tcl-50d05904e2652689f8352c49ba3ea9b256922bb0.tar.bz2
* win/tclWinInit.c: More careful calls to Tcl_DStringSetLength()
* win/tclWinSock.c: to avoid creating invalid DString states. * win/tclWinDde.c: Bump to version 1.3.2. [RFE 1366195] * library/dde/pkgIndex.tcl: * library/reg/pkgIndex.tcl: Bump to registry 1.1.6 * win/tclWinReg.c: * win/configure.in: Bump package version numbers. * win/configure: autoconf 2.59
Diffstat (limited to 'win/tclWinInit.c')
-rw-r--r--win/tclWinInit.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/win/tclWinInit.c b/win/tclWinInit.c
index f85448c..4703164 100644
--- a/win/tclWinInit.c
+++ b/win/tclWinInit.c
@@ -10,7 +10,7 @@
* See the file "license.terms" for information on usage and redistribution of
* this file, and for a DISCLAIMER OF ALL WARRANTIES.
*
- * RCS: @(#) $Id: tclWinInit.c,v 1.69 2006/02/08 21:41:28 dgp Exp $
+ * RCS: @(#) $Id: tclWinInit.c,v 1.70 2006/04/05 16:32:44 dgp Exp $
*/
#include "tclWinInt.h"
@@ -470,7 +470,9 @@ Tcl_GetEncodingNameFromEnvironment(
Tcl_DString *bufPtr)
{
Tcl_DStringInit(bufPtr);
+ Tcl_DStringSetLength(&bufPtr, 2+TCL_INTEGER_SPACE);
wsprintfA(Tcl_DStringValue(bufPtr), "cp%d", GetACP());
+ Tcl_DStringSetLength(&bufPtr, strlen(Tcl_DStringValue(bufPtr)));
return Tcl_DStringValue(bufPtr);
}