public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug fortran/51972] New: [OOP] ALLOCATE misses memset/calloc, causing segfault
@ 2012-01-23 17:44 burnus at gcc dot gnu.org
  2012-01-28 16:50 ` [Bug fortran/51972] " burnus at gcc dot gnu.org
                   ` (5 more replies)
  0 siblings, 6 replies; 7+ messages in thread
From: burnus at gcc dot gnu.org @ 2012-01-23 17:44 UTC (permalink / raw)
  To: gcc-bugs

http://gcc.gnu.org/bugzilla/show_bug.cgi?id=51972

             Bug #: 51972
           Summary: [OOP] ALLOCATE misses memset/calloc, causing segfault
    Classification: Unclassified
           Product: gcc
           Version: 4.7.0
            Status: UNCONFIRMED
          Keywords: wrong-code
          Severity: normal
          Priority: P3
         Component: fortran
        AssignedTo: unassigned@gcc.gnu.org
        ReportedBy: burnus@gcc.gnu.org


Created attachment 26435
  --> http://gcc.gnu.org/bugzilla/attachment.cgi?id=26435
Test case

The test case is a reduced version of chapter07/strategy_surrogate_f2003,
available from http://www.cambridge.org/rouson under "Resources available".

When compiling and running the program, one might get:
  Program received signal SIGABRT: Process abort signal.

Backtrace for this error:
  #6  0x400AC5 in __lorenz_module_MOD___copy_lorenz_module_Lorenz at
test.F90:42
  #7  0x401392 in __runge_kutta_2nd_module_MOD_integrate at test.F90:73
  #8  0x40153F in MAIN__ at test.F90:84


And with valgrind:
  Conditional jump or move depends on uninitialised value(s)
  at 0x400AD8: __lorenz_module_MOD___copy_lorenz_module_Lorenz (test.F90:42)
  by 0x4013B2: __runge_kutta_2nd_module_MOD_integrate (test.F90:73)


The issue is that there is MEMSET or CALLOC missing in "integrate". There is a
call to memset in "constructor" and "assign_lorenz".


^ permalink raw reply	[flat|nested] 7+ messages in thread

end of thread, other threads:[~2012-02-05  9:46 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2012-01-23 17:44 [Bug fortran/51972] New: [OOP] ALLOCATE misses memset/calloc, causing segfault burnus at gcc dot gnu.org
2012-01-28 16:50 ` [Bug fortran/51972] " burnus at gcc dot gnu.org
2012-01-28 17:42 ` burnus at gcc dot gnu.org
2012-01-28 19:01 ` burnus at gcc dot gnu.org
2012-01-29 21:25 ` [Bug fortran/51972] [OOP] Wrong code as _copy does not honor CLASS components burnus at gcc dot gnu.org
2012-01-29 21:42 ` burnus at gcc dot gnu.org
2012-02-05  9:46 ` burnus at gcc dot gnu.org

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).