* mmap.cc (fhandler_disk_file::mmap): Fix address test.

This commit is contained in:
Corinna Vinschen 2003-07-04 09:06:54 +00:00
parent baf77a53b0
commit 6694f3054e
2 changed files with 5 additions and 1 deletions

View File

@ -1,3 +1,7 @@
2003-07-04 Corinna Vinschen <corinna@vinschen.de>
* mmap.cc (fhandler_disk_file::mmap): Fix address test.
2003-07-03 Christopher Faylor <cgf@redhat.com>
* path.cc (fillout_mntent): Change "posix" to "managed".

View File

@ -820,7 +820,7 @@ fhandler_disk_file::mmap (caddr_t *addr, size_t len, DWORD access,
void *base = NULL;
/* If a non-zero address is given, try mapping using the given address first.
If it fails and flags is not MAP_FIXED, try again with NULL address. */
if (addr)
if (*addr)
base = MapViewOfFileEx (h, access, high, low, len, *addr);
if (!base && !(flags & MAP_FIXED))
base = MapViewOfFileEx (h, access, high, low, len, NULL);