This is the mail archive of the
mailing list for the GCC project.
Re: [PATCH] Fix ubsan ICE with flexible array members
- From: Jakub Jelinek <jakub at redhat dot com>
- To: Marek Polacek <polacek at redhat dot com>
- Cc: GCC Patches <gcc-patches at gcc dot gnu dot org>
- Date: Tue, 15 Jul 2014 13:02:23 +0200
- Subject: Re: [PATCH] Fix ubsan ICE with flexible array members
- Authentication-results: sourceware.org; auth=none
- References: <20140715110110 dot GC29766 at redhat dot com>
- Reply-to: Jakub Jelinek <jakub at redhat dot com>
On Tue, Jul 15, 2014 at 01:01:10PM +0200, Marek Polacek wrote:
> We were missing a check that the TYPE_MAX_VALUE is not NULL.
> If it is, we ICE later when gimplifying the UBSAN_BOUNDS call arguments.
> Bootstrapped/regtested on x86_64-linux, ok for trunk?
> 2014-07-15 Marek Polacek <email@example.com>
> * c-ubsan.c (ubsan_instrument_bounds): Don't instrument if
> TYPE_MAX_VALUE is NULL.
> * gcc.dg/ubsan/bounds-1.c: New test.