mirror of
https://github.com/jart/cosmopolitan.git
synced 2025-07-07 19:58:30 +00:00
Get cosmopolitation working on Vista again (#635)
* Fixes virtual memory support for Windows Vista/7/8 Fixes file desciptor and zipos virtual memory sizes given that old versions of windows limit their user virtual memory space to 8tb. Includes some changes fromb69f3d2488
and6f7d0cb1c3
in preparation for potentially using them on old windows and because it avoids duplicating addresses everywhere. * Optimise windows version checking Added GetNtMinorVersion() and IsAtleastWindows8p1() macros which get nt version info from the peb. * Planned nsync memory region for old windows Added nsync regon start and size macros that can switch to smaller values on old windows, just like previous fds and zipos change.
This commit is contained in:
parent
30140812f0
commit
4381b3d925
5 changed files with 30 additions and 12 deletions
|
@ -50,8 +50,8 @@ int __ensurefds_unlocked(int fd) {
|
|||
bool relocate;
|
||||
if (fd < g_fds.n) return fd;
|
||||
g_fds.n = fd + 1;
|
||||
g_fds.e =
|
||||
_extend(g_fds.p, g_fds.n * sizeof(*g_fds.p), g_fds.e, 0x6ff000000000);
|
||||
g_fds.e = _extend(g_fds.p, g_fds.n * sizeof(*g_fds.p), g_fds.e,
|
||||
kMemtrackFdsStart + kMemtrackFdsSize);
|
||||
return fd;
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue