diff options
author | jan.nijtmans <nijtmans@users.sourceforge.net> | 2014-02-04 21:33:13 (GMT) |
---|---|---|
committer | jan.nijtmans <nijtmans@users.sourceforge.net> | 2014-02-04 21:33:13 (GMT) |
commit | ae659fdb121c4054dec94b450182fc0b956e19f9 (patch) | |
tree | 58cf7d808c6aa74dc785c5d6d8dd7de58f2bd533 /unix/tclUnixInit.c | |
parent | 8c665116c9adbcca5d9f584aec632f97675ebb0e (diff) | |
parent | fc5e6debdee34caf68237de6750c1bb4c230e2bc (diff) | |
download | tcl-ae659fdb121c4054dec94b450182fc0b956e19f9.zip tcl-ae659fdb121c4054dec94b450182fc0b956e19f9.tar.gz tcl-ae659fdb121c4054dec94b450182fc0b956e19f9.tar.bz2 |
Add missing __stdcall (which crashes on win32), and clean-up indenting
Diffstat (limited to 'unix/tclUnixInit.c')
-rw-r--r-- | unix/tclUnixInit.c | 21 |
1 files changed, 11 insertions, 10 deletions
diff --git a/unix/tclUnixInit.c b/unix/tclUnixInit.c index f8acad5..7fe511b 100644 --- a/unix/tclUnixInit.c +++ b/unix/tclUnixInit.c @@ -865,16 +865,17 @@ TclpSetVariables( #ifdef __CYGWIN__ unameOK = 1; if (!osInfoInitialized) { - HANDLE handle = LoadLibraryW(L"NTDLL"); - int(*getversion)(void *) = (int(*)(void *))GetProcAddress(handle, "RtlGetVersion"); - osInfo.dwOSVersionInfoSize = sizeof(OSVERSIONINFOW); - if (!getversion || getversion(&osInfo)) { - GetVersionExW(&osInfo); - } - if (handle) { - FreeLibrary(handle); - } - osInfoInitialized = 1; + HANDLE handle = LoadLibraryW(L"NTDLL"); + __stdcall int(*getversion)(void *) = + (__stdcall int(*)(void *))GetProcAddress(handle, "RtlGetVersion"); + osInfo.dwOSVersionInfoSize = sizeof(OSVERSIONINFOW); + if (!getversion || getversion(&osInfo)) { + GetVersionExW(&osInfo); + } + if (handle) { + FreeLibrary(handle); + } + osInfoInitialized = 1; } GetSystemInfo(&sysInfo); |