From mboxrd@z Thu Jan 1 00:00:00 1970 X-Msuck: nntp://news.gmane.org/gmane.linux.lib.musl.general/4417 Path: news.gmane.org!not-for-mail From: David Wuertele Newsgroups: gmane.linux.lib.musl.general Subject: Re: NULL deref SEGV in malloc.c:unbin() Date: Fri, 27 Dec 2013 19:44:23 +0000 (UTC) Message-ID: References: <20131227190544.GF24286@brightrain.aerifal.cx> Reply-To: musl@lists.openwall.com NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit X-Trace: ger.gmane.org 1388173497 25095 80.91.229.3 (27 Dec 2013 19:44:57 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Fri, 27 Dec 2013 19:44:57 +0000 (UTC) To: musl@lists.openwall.com Original-X-From: musl-return-4421-gllmg-musl=m.gmane.org@lists.openwall.com Fri Dec 27 20:45:04 2013 Return-path: Envelope-to: gllmg-musl@plane.gmane.org Original-Received: from mother.openwall.net ([195.42.179.200]) by plane.gmane.org with smtp (Exim 4.69) (envelope-from ) id 1VwdLC-0003rX-O0 for gllmg-musl@plane.gmane.org; Fri, 27 Dec 2013 20:45:02 +0100 Original-Received: (qmail 15827 invoked by uid 550); 27 Dec 2013 19:45:01 -0000 Mailing-List: contact musl-help@lists.openwall.com; run by ezmlm Precedence: bulk List-Post: List-Help: List-Unsubscribe: List-Subscribe: Original-Received: (qmail 15819 invoked from network); 27 Dec 2013 19:45:01 -0000 X-Injected-Via-Gmane: http://gmane.org/ Original-Lines: 14 Original-X-Complaints-To: usenet@ger.gmane.org X-Gmane-NNTP-Posting-Host: sea.gmane.org User-Agent: Loom/3.14 (http://gmane.org/) X-Loom-IP: 205.234.27.227 (Mozilla/5.0 (Macintosh; Intel Mac OS X 10_9_0) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/31.0.1650.63 Safari/537.36) Xref: news.gmane.org gmane.linux.lib.musl.general:4417 Archived-At: Rich Felker aerifal.cx> writes: > On Fri, Dec 27, 2013 at 06:35:00PM +0000, David Wuertele wrote: > > I wonder if anyone has hit this before? In unbin(), c->next->prev is set, > > but c->next is NULL. It happens repeatedly, and here's what gdb says: > > It's almost surely a case of memory corruption by the calling program, > most likely using memory after it's already been freed. Hmm, my program calls malloc() once and never calls free(). Oh, I guess it does call free indirectly when it uses closedir() and fclose(). I will try to use gdb/watch to catch someone red-handed. Dave