aboutsummaryrefslogtreecommitdiff
path: root/gcc/cp
diff options
context:
space:
mode:
authorJason Merrill <jason@redhat.com>2015-11-25 13:58:06 -0500
committerJason Merrill <jason@gcc.gnu.org>2015-11-25 13:58:06 -0500
commit917124c30204d37a19f0f32f1fa14b3ae0add3b1 (patch)
tree1fd1eef5b8dac65b4c361716d4dfb4aa35fd4cca /gcc/cp
parentc217bac5d48b595182601eb08c92cae177a3bef2 (diff)
downloadgcc-917124c30204d37a19f0f32f1fa14b3ae0add3b1.zip
gcc-917124c30204d37a19f0f32f1fa14b3ae0add3b1.tar.gz
gcc-917124c30204d37a19f0f32f1fa14b3ae0add3b1.tar.bz2
cp-ubsan.c (cp_ubsan_instrument_vptr_p): Use do_ubsan_in_current_function.
* cp-ubsan.c (cp_ubsan_instrument_vptr_p): Use do_ubsan_in_current_function. From-SVN: r230896
Diffstat (limited to 'gcc/cp')
-rw-r--r--gcc/cp/ChangeLog5
-rw-r--r--gcc/cp/cp-ubsan.c4
2 files changed, 6 insertions, 3 deletions
diff --git a/gcc/cp/ChangeLog b/gcc/cp/ChangeLog
index c94ae5f..968482f 100644
--- a/gcc/cp/ChangeLog
+++ b/gcc/cp/ChangeLog
@@ -1,3 +1,8 @@
+2015-11-25 Jason Merrill <jason@redhat.com>
+
+ * cp-ubsan.c (cp_ubsan_instrument_vptr_p): Use
+ do_ubsan_in_current_function.
+
2015-11-25 Markus Trippelsdorf <markus@trippelsdorf.de>
Paolo Carlini <paolo.carlini@oracle.com>
diff --git a/gcc/cp/cp-ubsan.c b/gcc/cp/cp-ubsan.c
index 0aaf0af..e780c2e 100644
--- a/gcc/cp/cp-ubsan.c
+++ b/gcc/cp/cp-ubsan.c
@@ -32,9 +32,7 @@ cp_ubsan_instrument_vptr_p (tree type)
if (!flag_rtti || flag_sanitize_undefined_trap_on_error)
return false;
- if (current_function_decl
- && lookup_attribute ("no_sanitize_undefined",
- DECL_ATTRIBUTES (current_function_decl)))
+ if (!do_ubsan_in_current_function ())
return false;
if (type)