linux-c-programming.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: "Steve Graegert" <graegerts@gmail.com>
To: Shriramana Sharma <samjnaa@gmail.com>
Cc: linux-c-programming@vger.kernel.org
Subject: Re: "double free or corruption" - how to solve this?
Date: Fri, 12 May 2006 23:53:13 +0200	[thread overview]
Message-ID: <6a00c8d50605121453o2085e263v430a5c550b20cfde@mail.gmail.com> (raw)
In-Reply-To: <75062f40605120111s2d27c8c0gb768c50b1ae34588@mail.gmail.com>

On 5/12/06, Shriramana Sharma <samjnaa@gmail.com> wrote:
> One of my programs, which was working quite well till now, suddenly
> gives me the error:
>
> *** glibc detected *** double free or corruption (top): 0x0808a338 ***
> Aborted
>
> It is a pure C program compiled with GCC 4.02 -- I do not understand
> why it does not work suddenly. Please tell me what the above error can
> be.

Shriramana,

From earlier posts at SLE I suppose you're running SuSE 10 (please
correct me if I am wrong) which uses a glibc version with an
integrated memory checker that can be turned of by setting

export MALLOC_CHECK_=0

If the program is simple you will not have to use dbg in order to
locate the offending code if any.  A combination of electric fence (as
James suggested) and valgrind should do it.  OTOH, if you're using
some libs and/or have switched to a different glibc version recently
you may have some lib mess.  Anyway, try to figure out what's wrong
with using the tools mentioned here and post the code if possible and
give gdb a try.

Bye

	\Steve

  parent reply	other threads:[~2006-05-12 21:53 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2006-05-12  8:11 "double free or corruption" - how to solve this? Shriramana Sharma
2006-05-12  8:19 ` wwp
2006-05-12  8:45   ` Steve Graegert
2006-05-12 21:06     ` Nate Jenkins
2006-05-12 21:35       ` Steve Graegert
2006-05-12 21:46         ` Nate Jenkins
2006-05-12 12:01 ` james-lists
2006-05-12 21:53 ` Steve Graegert [this message]
  -- strict thread matches above, loose matches on Subject: below --
2006-05-12 20:40 AW: " Jedenastik, Günther
2006-05-12 22:18 ` Steve Graegert

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=6a00c8d50605121453o2085e263v430a5c550b20cfde@mail.gmail.com \
    --to=graegerts@gmail.com \
    --cc=linux-c-programming@vger.kernel.org \
    --cc=samjnaa@gmail.com \
    /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: link
Be 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 NNTP newsgroup(s).