public inbox for gcc-bugs@sourceware.org help / color / mirror / Atom feed
From: "kargl at gcc dot gnu dot org" <gcc-bugzilla@gcc.gnu.org> To: gcc-bugs@gcc.gnu.org Subject: [Bug fortran/39879] double free or corruption abort with gfortran Date: Fri, 24 Apr 2009 17:59:00 -0000 [thread overview] Message-ID: <20090424175909.26968.qmail@sourceware.org> (raw) In-Reply-To: <bug-39879-17588@http.gcc.gnu.org/bugzilla/> ------- Comment #6 from kargl at gcc dot gnu dot org 2009-04-24 17:59 ------- The problem is due to the null() in character(200), pointer :: descrip => null() If you comment out this statement or remove '=> null()', then the code compiles and runs. A slighly reduced testcase is module test_struct interface assignment (=) module procedure tao_lat_equal_tao_lat end interface type bunch_params_struct integer n_live_particle end type type tao_lattice_struct type (bunch_params_struct), allocatable :: bunch_params(:) type (bunch_params_struct), allocatable :: bunch_params2(:) end type type tao_universe_struct type (tao_lattice_struct), pointer :: model, design character(200), pointer :: descrip => null() end type type tao_super_universe_struct type (tao_universe_struct), allocatable :: u(:) end type type (tao_super_universe_struct), save, target :: s contains subroutine tao_lat_equal_tao_lat (lat1, lat2) implicit none type (tao_lattice_struct), intent(inout) :: lat1 type (tao_lattice_struct), intent(in) :: lat2 end subroutine end module program tao_program use test_struct implicit none type (tao_universe_struct), pointer :: u integer n allocate (s%u(1)) u => s%u(1) allocate (u%design, u%model) n = 112 allocate (u%model%bunch_params(0:n), u%design%bunch_params(0:n)) u%model = u%design u%model = u%design end program -- http://gcc.gnu.org/bugzilla/show_bug.cgi?id=39879
next prev parent reply other threads:[~2009-04-24 17:59 UTC|newest] Thread overview: 18+ messages / expand[flat|nested] mbox.gz Atom feed top 2009-04-24 6:35 [Bug fortran/39879] New: " david dot sagan at gmail dot com 2009-04-24 6:36 ` [Bug fortran/39879] " david dot sagan at gmail dot com 2009-04-24 8:55 ` dominiq at lps dot ens dot fr 2009-04-24 13:06 ` david dot sagan at gmail dot com 2009-04-24 14:17 ` kargl at gcc dot gnu dot org 2009-04-24 14:27 ` david dot sagan at gmail dot com 2009-04-24 17:59 ` kargl at gcc dot gnu dot org [this message] 2009-04-24 18:00 ` kargl at gcc dot gnu dot org 2009-04-24 22:03 ` [Bug fortran/39879] [4.3/4.4/4.5 Regression] " burnus at gcc dot gnu dot org 2009-04-25 18:06 ` pault at gcc dot gnu dot org 2009-04-26 16:50 ` pault at gcc dot gnu dot org 2009-04-26 19:22 ` pault at gcc dot gnu dot org 2009-04-28 5:16 ` pault at gcc dot gnu dot org 2009-04-28 5:30 ` pault at gcc dot gnu dot org 2009-04-28 6:07 ` [Bug fortran/39879] [4.3/4.4 " pault at gcc dot gnu dot org 2009-05-10 10:44 ` pault at gcc dot gnu dot org 2009-05-10 16:09 ` pault at gcc dot gnu dot org 2009-05-10 16:10 ` pault at gcc dot gnu dot org
Reply instructions: You may reply publicly to this message via plain-text email using any one of the following methods: * Save the following mbox file, import it into your mail client, and reply-to-all from there: mbox Avoid top-posting and favor interleaved quoting: https://en.wikipedia.org/wiki/Posting_style#Interleaved_style * Reply using the --to, --cc, and --in-reply-to switches of git-send-email(1): git send-email \ --in-reply-to=20090424175909.26968.qmail@sourceware.org \ --to=gcc-bugzilla@gcc.gnu.org \ --cc=gcc-bugs@gcc.gnu.org \ /path/to/YOUR_REPLY https://kernel.org/pub/software/scm/git/docs/git-send-email.html * If your mail client supports setting the In-Reply-To header via mailto: links, try the mailto: linkBe sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions for how to clone and mirror all data and code used for this inbox; as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).