From a43676d2e4eec7523a63484801e9c29ba1978659 Mon Sep 17 00:00:00 2001 From: Paul Floyd Date: Sun, 24 Aug 2025 00:05:51 +0200 Subject: [PATCH] FreeBSD regtest: updates to scalar for x86 Now that there better checks of fds a couple of syscalls using rubbish values for fd which were above the max files limit. That changed the syscall return code causing an assert. Also some left over updates to the expected from previous changes. --- memcheck/tests/freebsd/scalar.c | 4 ++-- memcheck/tests/freebsd/scalar.stderr.exp-x86 | 10 +++++++++- 2 files changed, 11 insertions(+), 3 deletions(-) diff --git a/memcheck/tests/freebsd/scalar.c b/memcheck/tests/freebsd/scalar.c index 234e649f7..0709d1873 100644 --- a/memcheck/tests/freebsd/scalar.c +++ b/memcheck/tests/freebsd/scalar.c @@ -1989,13 +1989,13 @@ int main(void) SY(SYS_posix_fallocate, x0+99999, x0+10, x0+20); SUCC; #else GO(SYS_posix_fallocate, "5s 0m"); - SY(SYS_posix_fallocate, x0+99999, x0, x0+10, x0, x0+20); SUCC; + SY(SYS_posix_fallocate, x0+9999, x0, x0+10, x0, x0+20); SUCC; #endif assert(res == EBADF); /* SYS_posix_fadvise 531 */ GO(SYS_posix_fadvise, "4s 0m"); - SY(SYS_posix_fadvise, x0+99999, x0+10, x0+20, x0); SUCC; + SY(SYS_posix_fadvise, x0+9999, x0+10, x0+20, x0); SUCC; assert(res == EBADF); /* SYS_wait6 532 */ diff --git a/memcheck/tests/freebsd/scalar.stderr.exp-x86 b/memcheck/tests/freebsd/scalar.stderr.exp-x86 index 40d091995..20d8d3ca7 100644 --- a/memcheck/tests/freebsd/scalar.stderr.exp-x86 +++ b/memcheck/tests/freebsd/scalar.stderr.exp-x86 @@ -2068,6 +2068,10 @@ Syscall param preadv(offset_low) contains uninitialised byte(s) Syscall param preadv(offset_high) contains uninitialised byte(s) ... +Syscall param preadv(iov) points to unaddressable byte(s) + ... + Address 0x........ is not stack'd, malloc'd or (recently) free'd + --------------------------------------------------------- 290: SYS_pwritev 5s 0m --------------------------------------------------------- @@ -2086,6 +2090,10 @@ Syscall param pwritev(offset_low) contains uninitialised byte(s) Syscall param pwritev(offset_high) contains uninitialised byte(s) ... +Syscall param pwritev(vector) points to unaddressable byte(s) + ... + Address 0x........ is not stack'd, malloc'd or (recently) free'd + --------------------------------------------------------- 298: SYS_fhopen 2s 1m --------------------------------------------------------- @@ -3957,7 +3965,7 @@ Syscall param mmap(offset_high) contains uninitialised byte(s) --------------------------------------------------------- 478: SYS_lseek 4s 0m --------------------------------------------------------- -Syscall param lseek(fd) contains uninitialised byte(s) +Syscall param lseek(fildes) contains uninitialised byte(s) ... Syscall param lseek(offset_low) contains uninitialised byte(s) -- 2.47.3