This is the mail archive of the
fortran@gcc.gnu.org
mailing list for the GNU Fortran project.
Re: bug realloc-lhs
- From: Steve Kargl <sgk at troutmask dot apl dot washington dot edu>
- To: "patnel97269-gfortran at yahoo dot fr" <patnel97269-gfortran at yahoo dot fr>
- Cc: "fortran at gcc dot gnu dot org" <fortran at gcc dot gnu dot org>
- Date: Tue, 27 Mar 2012 12:20:19 -0700
- Subject: Re: bug realloc-lhs
- References: <1332875169.9730.YahooMailNeo@web132403.mail.ird.yahoo.com>
On Tue, Mar 27, 2012 at 08:06:09PM +0100, patnel97269-gfortran@yahoo.fr wrote:
> Hi all,
>
> I want to report a bug concerning the realloc-lhs, in case of a type containing a allocatable array.?
> For just an allocatable array it's ok ,everything works fine, when i deallocate the array in a function it's reallocated with the "=" statement;
> But for a type i got a double free corruption, so i think there a test here to know if the array in the type is allocated or not. Note that if i don't allocate the array in the type at the beginning without deallocating it works.?
>
> Here is the code .
Looks like the type of problem, one might expect from
invoking a function with side-effect.
--
Steve