Welcome to mirror list, hosted at ThFree Co, Russian Federation.

cygwin.com/git/newlib-cygwin.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorCorinna Vinschen <corinna@vinschen.de>2006-01-10 21:11:32 +0300
committerCorinna Vinschen <corinna@vinschen.de>2006-01-10 21:11:32 +0300
commitb773a592d3dfea4525c852a1d98540aa86bc0e43 (patch)
tree10f26be64fbe4b3dfa4384928e8c9b72267ce323 /winsup/cygwin/wincap.cc
parentdea958bc0612f79a603e4a8a915c8beeafc464e1 (diff)
* dcrt0.cc (dll_crt0_0): Remove call to wincap.init.
* init.cc (dll_entry): Rename is_wow64_proc to wow64_test_stack_marker. Call wincap.init here before doing anything else. Use wincap.is_wow64 to determine if we're running in a WOW64 emulator. * mmap.cc (MapViewNT): Don't use AT_ROUND_TO_PAGE in WOW64, it's apparently not supported. (mmap64): Don't create mappings beyond EOF, which would need to use AT_ROUND_TO_PAGE, on WOW64. * wincap.cc (wincap): Throw into the .cygwin_dll_common section. (wincapc::init): Determine if running in WOW64 and set wow_64 flag. * wincap.h (class wincapc): Add wow64 member. (wincapc::is_wow64): New method.
Diffstat (limited to 'winsup/cygwin/wincap.cc')
-rw-r--r--winsup/cygwin/wincap.cc6
1 files changed, 5 insertions, 1 deletions
diff --git a/winsup/cygwin/wincap.cc b/winsup/cygwin/wincap.cc
index 898f098c6..329cfec69 100644
--- a/winsup/cygwin/wincap.cc
+++ b/winsup/cygwin/wincap.cc
@@ -713,7 +713,7 @@ static NO_COPY wincaps wincap_vista = {
has_working_virtual_lock:true
};
-wincapc wincap;
+wincapc wincap __attribute__((section (".cygwin_dll_common"), shared));
void
wincapc::init ()
@@ -820,6 +820,10 @@ wincapc::init ()
((wincaps *)this->caps)->is_server = true;
}
+ BOOL is_wow64_proc = FALSE;
+ if (IsWow64Process (GetCurrentProcess (), &is_wow64_proc))
+ wow64 = is_wow64_proc;
+
__small_sprintf (osnam, "%s-%d.%d", os, version.dwMajorVersion,
version.dwMinorVersion);
}