* mmap.cc (mmap64): Fix returned address by taking the granularity
into account.
This commit is contained in:
parent
c8926a2b8d
commit
6b9a9ce6ba
@ -1,3 +1,8 @@
|
|||||||
|
2003-02-25 Corinna Vinschen <corinna@vinschen.de>
|
||||||
|
|
||||||
|
* mmap.cc (mmap64): Fix returned address by taking the granularity
|
||||||
|
into account.
|
||||||
|
|
||||||
2003-02-23 Pierre Humblet <pierre.humblet@ieee.org>
|
2003-02-23 Pierre Humblet <pierre.humblet@ieee.org>
|
||||||
|
|
||||||
* syslog.cc (syslog): Do not unlock the file before closing it
|
* syslog.cc (syslog): Do not unlock the file before closing it
|
||||||
|
@ -577,7 +577,7 @@ mmap64 (caddr_t addr, size_t len, int prot, int flags, int fd, __off64_t off)
|
|||||||
|
|
||||||
/* Insert into the list */
|
/* Insert into the list */
|
||||||
mmap_record *rec = map_list->add_record (mmap_rec, off, len);
|
mmap_record *rec = map_list->add_record (mmap_rec, off, len);
|
||||||
caddr_t ret = rec->get_address () + off;
|
caddr_t ret = rec->get_address () + (off - gran_off);
|
||||||
syscall_printf ("%x = mmap() succeeded", ret);
|
syscall_printf ("%x = mmap() succeeded", ret);
|
||||||
ReleaseResourceLock (LOCK_MMAP_LIST, READ_LOCK | WRITE_LOCK, "mmap");
|
ReleaseResourceLock (LOCK_MMAP_LIST, READ_LOCK | WRITE_LOCK, "mmap");
|
||||||
return ret;
|
return ret;
|
||||||
|
Loading…
x
Reference in New Issue
Block a user