forked from OSchip/llvm-project
parent
b76dcd17d1
commit
ee59c5e922
|
@ -32,12 +32,14 @@ void A::f() {}
|
|||
int main(int argc, char *argv[]) {
|
||||
void *p = create_B();
|
||||
// CHECK: runtime error: control flow integrity check for type 'A' failed during cast to unrelated type
|
||||
// CHECK: invalid vtable in module {{.*}}libtarget_uninstrumented.cpp.dynamic.so
|
||||
// CHECK: invalid vtable
|
||||
// CHECK: check failed in {{.*}}, vtable located in {{.*}}libtarget_uninstrumented.cpp.dynamic.so
|
||||
A *a = (A *)p;
|
||||
memset(p, 0, sizeof(A));
|
||||
|
||||
// CHECK: runtime error: control flow integrity check for type 'A' failed during cast to unrelated type
|
||||
// CHECK-NOT: invalid vtable in module
|
||||
// CHECK: invalid vtable
|
||||
// CHECK: check failed in {{.*}}, vtable located in (unknown)
|
||||
a = (A *)p;
|
||||
// CHECK: done
|
||||
fprintf(stderr, "done %p\n", a);
|
||||
|
|
Loading…
Reference in New Issue