* mmap.cc (fhandler_disk_file::mmap): Use `addr' correctly.
* fhandler_mem.cc (fhandler_dev_mem::mmap): Ditto.
This commit is contained in:
parent
55a96ae8b3
commit
675412e9d6
|
@ -1,3 +1,8 @@
|
||||||
|
Fri Feb 23 10:42:00 2001 Corinna Vinschen <corinna@vinschen.de>
|
||||||
|
|
||||||
|
* mmap.cc (fhandler_disk_file::mmap): Use `addr' correctly.
|
||||||
|
* fhandler_mem.cc (fhandler_dev_mem::mmap): Ditto.
|
||||||
|
|
||||||
Thu Feb 22 17:09:00 2001 Corinna Vinschen <corinna@vinschen.de>
|
Thu Feb 22 17:09:00 2001 Corinna Vinschen <corinna@vinschen.de>
|
||||||
|
|
||||||
* path.cc (symlink): Keep relative paths relative in the DOS
|
* path.cc (symlink): Keep relative paths relative in the DOS
|
||||||
|
|
|
@ -332,7 +332,7 @@ fhandler_dev_mem::mmap (caddr_t *addr, size_t len, DWORD access,
|
||||||
syscall_printf ("-1 = mmap(): NtMapViewOfSection failed with %E");
|
syscall_printf ("-1 = mmap(): NtMapViewOfSection failed with %E");
|
||||||
return INVALID_HANDLE_VALUE;
|
return INVALID_HANDLE_VALUE;
|
||||||
}
|
}
|
||||||
if ((flags & MAP_FIXED) && base != addr)
|
if ((flags & MAP_FIXED) && base != *addr)
|
||||||
{
|
{
|
||||||
set_errno (EINVAL);
|
set_errno (EINVAL);
|
||||||
syscall_printf ("-1 = mmap(): address shift with MAP_FIXED given");
|
syscall_printf ("-1 = mmap(): address shift with MAP_FIXED given");
|
||||||
|
|
|
@ -729,9 +729,9 @@ fhandler_disk_file::mmap (caddr_t *addr, size_t len, DWORD access,
|
||||||
}
|
}
|
||||||
|
|
||||||
void *base = MapViewOfFileEx (h, access, 0, off, len,
|
void *base = MapViewOfFileEx (h, access, 0, off, len,
|
||||||
(flags & MAP_FIXED) ? addr : NULL);
|
(flags & MAP_FIXED) ? *addr : NULL);
|
||||||
|
|
||||||
if (!base || ((flags & MAP_FIXED) && base != addr))
|
if (!base || ((flags & MAP_FIXED) && base != *addr))
|
||||||
{
|
{
|
||||||
if (!base)
|
if (!base)
|
||||||
{
|
{
|
||||||
|
|
Loading…
Reference in New Issue