glibc detected *** python: corrupted double-linked list

Duncan Grisby duncan-news at grisby.org
Wed Feb 25 12:55:44 EST 2009


In article <mailman.730.1235567202.11746.python-list at python.org>,
David Cournapeau  <cournape at gmail.com> wrote:

[...]
>It is very unlikely the problem is in glibc - I would check your code
>carefully first :) On Linux, the following are useful:

You are right that it is extremely unlikely that the bug is in glibc.
However, it is not impossible. Several of my colleagues and I spent
months trying to track down a bug where Python would occasionally
crash with a segfault while iterating through large lists. Of course
the problem only ever happened on customer sites, and not in our lab.
I eventually tracked it down to a bug in glibc's realloc()
implementation, where once in a blue moon it would fail to copy all
the data into the newly-allocated buffer.

It turned out to be a bug that had been found before, but had been
closed as invalid a few months earlier:

  http://sources.redhat.com/bugzilla/show_bug.cgi?id=5743

The fix had then been applied about a week before I found it myself.

I'm not sure that particular fix has found it into any of the major
Linux distributions yet.

Cheers,

Duncan.

-- 
 -- Duncan Grisby         --
  -- duncan at grisby.org     --
   -- http://www.grisby.org --



More information about the Python-list mailing list