Sign in
gnu
/
gcc
/
refs/tags/basepoints/gcc-13
/
.
/
gcc
/
testsuite
/
c-c++-common
/
ubsan
/
null-3.c
blob: e9e8b7bd2133736863b1f63cc2b70c14c4b9f409 [
file
] [
log
] [
blame
]
/* { dg-do run } */
/* { dg-options "-fsanitize=null -w" } */
/* { dg-shouldfail "ubsan" } */
int
foo
(
int
*
p
)
{
return
*
p
;
}
int
main
(
void
)
{
int
**
p
=
0
;
return
foo
(*
p
);
}
/* { dg-output "load of null pointer of type 'int \\*'" } */