[Patch, fortran] PR87359 [9 regression] pointer being freed was not allocated

Paul Richard Thomas paul.richard.thomas@gmail.com
Fri Sep 21 17:40:00 GMT 2018


This bug was something of a disaster for Jeurgen Reuter and so I set
to it right away. Jeurgen's reduction of the failing programs save a
huge amount of time and the fix turned out to be a one-liner.

Committed after testing by Dominique.

Bootstrapped and regtested on FC28/x86_64.

Paul

Author: pault
Date: Fri Sep 21 17:26:23 2018
New Revision: 264485

URL: https://gcc.gnu.org/viewcvs?rev=264485&root=gcc&view=rev
Log:
2018-09-21  Paul Thomas  <pault@gcc.gnu.org>

        PR fortran/87359
        * trans-stmt.c (gfc_trans_allocate): Don't deallocate alloc
        components if must_finalize is set for expr3.

2018-09-21  Paul Thomas  <pault@gcc.gnu.org>

        PR fortran/87359
        * gfortran.dg/finalize_33.f90 : New test.


Added:
    trunk/gcc/testsuite/gfortran.dg/finalize_33.f90
Modified:
    trunk/gcc/fortran/ChangeLog
    trunk/gcc/fortran/trans-stmt.c
    trunk/gcc/testsuite/ChangeLog

--
You are receiving this mail because:
You are on the CC list for the bug.
You are the assignee for the bug.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: submit.diff
Type: text/x-patch
Size: 5317 bytes
Desc: not available
URL: <http://gcc.gnu.org/pipermail/fortran/attachments/20180921/5e5ce726/attachment.bin>


More information about the Fortran mailing list