* sysdeps/mach/hurd/dl-sysdep.c (__mmap): Use MAP_FAILED instead of

widening __hurd_fail value.
This commit is contained in:
Roland McGrath 2002-04-08 07:11:55 +00:00
parent f899db6094
commit b82006e0b5
2 changed files with 6 additions and 1 deletions

View File

@ -1,3 +1,8 @@
2002-04-08 Roland McGrath <roland@frob.com>
* sysdeps/mach/hurd/dl-sysdep.c (__mmap): Use MAP_FAILED instead of
widening __hurd_fail value.
2002-04-07 Roland McGrath <roland@frob.com>
* sysdeps/mach/hurd/alpha/trampoline.c: Don't include

View File

@ -448,7 +448,7 @@ __mmap (__ptr_t addr, size_t len, int prot, int flags, int fd, off_t offset)
assert (!(flags & MAP_SHARED));
err = __io_map ((mach_port_t) fd, &memobj_rd, &memobj_wr);
if (err)
return (__ptr_t) __hurd_fail (err);
return __hurd_fail (err), MAP_FAILED;
__mach_port_deallocate (__mach_task_self (), memobj_wr);
}