diff options
author | chengyemao <chengyemao@noemail.net> | 2003-02-27 03:47:08 (GMT) |
---|---|---|
committer | chengyemao <chengyemao@noemail.net> | 2003-02-27 03:47:08 (GMT) |
commit | 0534ebe8a5c4f565c7cd2a3c204a72d7cb4d3c41 (patch) | |
tree | d86d66837b07e02dff13c7eb4e641239b123512a | |
parent | 18b22e9746095eea68a15e4a5406256058ba7dd3 (diff) | |
download | tcl-0534ebe8a5c4f565c7cd2a3c204a72d7cb4d3c41.zip tcl-0534ebe8a5c4f565c7cd2a3c204a72d7cb4d3c41.tar.gz tcl-0534ebe8a5c4f565c7cd2a3c204a72d7cb4d3c41.tar.bz2 |
Fixed a bug in TclpSetVeriables: initialize dwUserNameLen to avoid crash in calling GetUserName
FossilOrigin-Name: 40b46bfcb544c7c42c779dca7c15396790fea7a4
-rw-r--r-- | win/tclWinInit.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/win/tclWinInit.c b/win/tclWinInit.c index a61d59a..2ab64a3 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.39 2003/02/13 23:49:48 kennykb Exp $ + * RCS: @(#) $Id: tclWinInit.c,v 1.40 2003/02/27 03:47:09 chengyemao Exp $ */ #include "tclWinInt.h" @@ -599,7 +599,7 @@ TclpSetVariables(interp) OSVERSIONINFOA osInfo; Tcl_DString ds; TCHAR szUserName[ UNLEN+1 ]; - DWORD dwUserNameLen; + DWORD dwUserNameLen = sizeof(szUserName); osInfo.dwOSVersionInfoSize = sizeof(OSVERSIONINFOA); GetVersionExA(&osInfo); |