selftests/mm: fix WARNING comparing pointer to 0
Remove comparing pointer to 0 to avoid this warning from coccinelle: ./tools/testing/selftests/mm/map_populate.c:80:16-17: WARNING comparing pointer to 0, suggest !E ./tools/testing/selftests/mm/map_populate.c:80:16-17: WARNING comparing pointer to 0 Link: https://lkml.kernel.org/r/20230817160033.90079-1-tuananhlfc@gmail.com Signed-off-by: Anh Tuan Phan <tuananhlfc@gmail.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
This commit is contained in:
parent
7131fd7e30
commit
bad5a3a42a
@ -77,7 +77,7 @@ int main(int argc, char **argv)
|
||||
unsigned long *smap;
|
||||
|
||||
ftmp = tmpfile();
|
||||
BUG_ON(ftmp == 0, "tmpfile()");
|
||||
BUG_ON(!ftmp, "tmpfile()");
|
||||
|
||||
ret = ftruncate(fileno(ftmp), MMAP_SZ);
|
||||
BUG_ON(ret, "ftruncate()");
|
||||
|
Loading…
Reference in New Issue
Block a user