diff options
Diffstat (limited to 'winsup/cygwin/uname.cc')
-rw-r--r-- | winsup/cygwin/uname.cc | 9 |
1 files changed, 7 insertions, 2 deletions
diff --git a/winsup/cygwin/uname.cc b/winsup/cygwin/uname.cc index fa89373d2..3797b140d 100644 --- a/winsup/cygwin/uname.cc +++ b/winsup/cygwin/uname.cc @@ -36,10 +36,15 @@ uname (struct utsname *name) build systems which think the native system is a 64 bit system. Since we're actually running in a 32 bit environment, it looks more correct just to use the CPU info given by WOW64. */ - BOOL is_64bit_machine = FALSE; - if (IsWow64Process (hMainProc, &is_64bit_machine) && is_64bit_machine) + if (wincap.is_wow64 ()) GetNativeSystemInfo (&sysinfo); else +#else + /* But it seems ok to add a hint to the sysname, that we're running under + WOW64. This might give an early clue if somebody encounters problems. */ + if (wincap.is_wow64 ()) + strncat (name->sysname, "-WOW64", + sizeof name->sysname - strlen (name->sysname) - 1); #endif GetSystemInfo (&sysinfo); |