mirror of
git://git.sv.gnu.org/emacs.git
synced 2026-01-06 03:40:56 -08:00
(mmap_realloc): When shrinking, make sure number of
pages is rounded towards zero.
This commit is contained in:
parent
90dc758dc0
commit
bb63c5c9b8
2 changed files with 6 additions and 1 deletions
|
|
@ -4670,7 +4670,7 @@ mmap_realloc (var, nbytes)
|
|||
{
|
||||
/* Shrinking by at least a page. Let's give some
|
||||
memory back to the system. */
|
||||
mmap_enlarge (r, - (room - nbytes) / mmap_page_size);
|
||||
mmap_enlarge (r, - ((room - nbytes) / mmap_page_size));
|
||||
result = *var;
|
||||
r->nbytes_specified = nbytes;
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue