This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug sanitizer/81604] Ubsan type reporting can be bogus in some cases
- From: "jakub at gcc dot gnu.org" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: Mon, 31 Jul 2017 09:30:36 +0000
- Subject: [Bug sanitizer/81604] Ubsan type reporting can be bogus in some cases
- Auto-submitted: auto-generated
- References: <bug-81604-4@http.gcc.gnu.org/bugzilla/>
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=81604
--- Comment #5 from Jakub Jelinek <jakub at gcc dot gnu.org> ---
Author: jakub
Date: Mon Jul 31 09:29:58 2017
New Revision: 250733
URL: https://gcc.gnu.org/viewcvs?rev=250733&root=gcc&view=rev
Log:
PR sanitizer/81604
* ubsan.c (ubsan_type_descriptor): For UBSAN_PRINT_ARRAY don't
change type to the element type, instead add eltype variable and
use it where we are interested in the element type.
* c-c++-common/ubsan/pr81604.c: New test.
Added:
branches/gcc-5-branch/gcc/testsuite/c-c++-common/ubsan/pr81604.c
Modified:
branches/gcc-5-branch/gcc/ChangeLog
branches/gcc-5-branch/gcc/testsuite/ChangeLog
branches/gcc-5-branch/gcc/ubsan.c