Skip to content

Commit 2af7302

Browse files
committed
syscalls/mbind01: Use SAFE_MMAP()
Signed-off-by: Petr Vorel <[email protected]>
1 parent 6efe969 commit 2af7302

File tree

1 file changed

+1
-3
lines changed

1 file changed

+1
-3
lines changed

testcases/kernel/syscalls/mbind/mbind01.c

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -170,10 +170,8 @@ static void do_test(unsigned int i)
170170

171171
setup_node();
172172

173-
p = mmap(NULL, MEM_LENGTH, PROT_READ | PROT_WRITE, MAP_PRIVATE |
173+
p = SAFE_MMAP(NULL, MEM_LENGTH, PROT_READ | PROT_WRITE, MAP_PRIVATE |
174174
MAP_ANONYMOUS, 0, 0);
175-
if (p == MAP_FAILED)
176-
tst_brk(TBROK | TERRNO, "mmap");
177175

178176
tc->test(i, p);
179177

0 commit comments

Comments
 (0)