[LTP] [PATCH] syscalls/mmap15: relax condition a bit
Jan Stancek
jstancek@redhat.com
Thu Sep 13 10:30:48 CEST 2018
High address is arch specific, and it also occasionally changes
as can be seen in history of this test.
Relax the condition and accept both ENOMEM and EINVAL
as expected outcome.
Fixes: #390
Signed-off-by: Jan Stancek <jstancek@redhat.com>
---
testcases/kernel/syscalls/mmap/mmap15.c | 5 ++---
1 file changed, 2 insertions(+), 3 deletions(-)
diff --git a/testcases/kernel/syscalls/mmap/mmap15.c b/testcases/kernel/syscalls/mmap/mmap15.c
index eff27d6585e0..c8a77873a254 100644
--- a/testcases/kernel/syscalls/mmap/mmap15.c
+++ b/testcases/kernel/syscalls/mmap/mmap15.c
@@ -80,10 +80,9 @@ int main(int ac, char **av)
continue;
}
- if (errno != ENOMEM) {
+ if (errno != ENOMEM && errno != EINVAL) {
tst_resm(TFAIL | TERRNO, "mmap into high region "
- "failed unexpectedly - expect "
- "errno=ENOMEM, got");
+ "failed unexpectedly");
} else {
tst_resm(TPASS | TERRNO, "mmap into high region "
"failed as expected");
--
1.8.3.1
More information about the ltp
mailing list