mirror of
https://git.savannah.gnu.org/git/guile.git
synced 2025-05-21 20:20:24 +02:00
Do not warn the user when 'madvise' returns ENOSYS.
* libguile/vm.c (return_unused_stack_to_os): Avoid 'perror' calls when 'madvise' returns ENOSYS.
This commit is contained in:
parent
1b0fcddba5
commit
abeeec74b2
1 changed files with 4 additions and 1 deletions
|
@ -660,7 +660,10 @@ return_unused_stack_to_os (struct scm_vm *vp)
|
||||||
ret = madvise ((void *) lo, hi - lo, MADV_DONTNEED);
|
ret = madvise ((void *) lo, hi - lo, MADV_DONTNEED);
|
||||||
while (ret && errno == EAGAIN);
|
while (ret && errno == EAGAIN);
|
||||||
|
|
||||||
if (ret)
|
/* If the OS doesn't implement 'madvise' (as is currently the case
|
||||||
|
for GNU/Hurd), don't warn the user since there's nothing they
|
||||||
|
can do about it. */
|
||||||
|
if (ret && errno != ENOSYS)
|
||||||
perror ("madvise failed");
|
perror ("madvise failed");
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue