[LTP] syscall02: test invalid syscall number -1
linuxtestproject.agent@gmail.com
linuxtestproject.agent@gmail.com
Tue Jul 14 12:50:11 CEST 2026
Hi Andrea,
On Tue, 14 Jul 2026 11:25:40 +0200, Andrea Cervesato wrote:
> syscall02: test invalid syscall number -1
> +#include <unistd.h>
> +#include <sys/syscall.h>
<sys/syscall.h> provides SYS_* constants, but none are used here.
syscall() is declared by <unistd.h>. The include can be dropped.
> + * Verify that a raw :manpage:`syscall(2)` with the reserved system call
> + * number -1 fails with ENOSYS.
Same in the commit message body: -1 is not formally reserved by the
kernel ABI or POSIX. It is simply an out-of-range number that lands on
sys_ni_syscall. The test itself uses "invalid" in the message string,
which is the more accurate term. Worth aligning the description with
that wording.
Verdict - Needs revision
---
Note:
The agent can sometimes produce false positives although often its
findings are genuine. If you find issues with the review, please
comment this email or ignore the suggestions.
Regards,
LTP AI Reviewer
More information about the ltp
mailing list