Fix c/69522, memory management issue in c-parser

Bernd Schmidt bschmidt@redhat.com
Tue Feb 16 14:22:00 GMT 2016


On 02/08/2016 05:30 PM, Jeff Law wrote:
> On 01/29/2016 04:40 AM, Bernd Schmidt wrote:
>> c/
>>     PR c/69522
>>     * c-parser.c (c_parser_braced_init): New arg outer_obstack.  All
>>     callers changed.  If nested_p is true, use it to call
>>     finish_implicit_inits.
>>     * c-tree.h (finish_implicit_inits): Declare.
>>     * c-typeck.c (finish_implicit_inits): New function.  Move code
>>     from ...
>>     (push_init_level): ... here.
>>     (set_designator, process_init_element): Call finish_implicit_inits.
>>
>> testsuite/
>>     PR c/69522
>>     gcc.dg/pr69522.c: New test.
> OK.  Thanks for tracking this down.

Ok for branches too?


Bernd



More information about the Gcc-patches mailing list