FreeBSD shm_open2 also accepts first argument as SHM_ANON

Add an extra test to scalar
This commit is contained in:
Paul Floyd 2022-05-09 21:27:36 +02:00
parent d99b369c09
commit 35fcf875c6
2 changed files with 27 additions and 1 deletions

View File

@ -1,4 +1,5 @@
#include "scalar.h"
#include <sys/mman.h>
int main(void)
{
@ -7,7 +8,10 @@ int main(void)
/* SYS_shm_open2 571 */
GO(SYS_shm_open2, " 5s 2m");
SY(SYS_shm_open2, x0, x0+1, x0+2, x0+3, x0+4); FAIL;
SY(SYS_shm_open2, x0+0xf00c, x0+1, x0+2, x0+3, x0+4); FAIL;
GO(SYS_shm_open2, " 5s 1m");
SY(SYS_shm_open2, x0+SHM_ANON, x0+1, x0+2, x0+3, x0+4); FAIL;
/* SYS___realpathat 574 */
GO(SYS___realpathat, " 5s 2m");

View File

@ -24,6 +24,28 @@ Syscall param shm_open2(name) points to unaddressable byte(s)
...
Address 0x........ is not stack'd, malloc'd or (recently) free'd
---------------------------------------------------------
571: SYS_shm_open2 5s 1m
---------------------------------------------------------
Syscall param shm_open2(path) contains uninitialised byte(s)
...
Syscall param shm_open2(flags) contains uninitialised byte(s)
...
Syscall param shm_open2(mode) contains uninitialised byte(s)
...
Syscall param shm_open2(shmflags) contains uninitialised byte(s)
...
Syscall param shm_open2(name) contains uninitialised byte(s)
...
Syscall param shm_open2(name) points to unaddressable byte(s)
...
Address 0x........ is not stack'd, malloc'd or (recently) free'd
---------------------------------------------------------
574: SYS___realpathat 5s 2m
---------------------------------------------------------