Path: utzoo!utgpu!utstat!jarvis.csri.toronto.edu!mailrus!tut.cis.ohio-state.edu!rutgers!cmcl2!adm!smoke!gwyn From: gwyn@smoke.BRL.MIL (Doug Gwyn ) Newsgroups: comp.lang.c Subject: Re: malloc hangs indefinitely Message-ID: <9544@smoke.BRL.MIL> Date: 31 Jan 89 07:55:20 GMT References: <489@marob.MASA.COM> Reply-To: gwyn@brl.arpa (Doug Gwyn (VLD/VMB) ) Organization: Ballistic Research Lab (BRL), APG, MD. Lines: 10 In article <489@marob.MASA.COM> daveh@marob.masa.com (Dave Hammond) writes: >My guess is that malloc is in an infinite loop looking for suitable >space in its heap. Any suggestions on what might cause malloc to >spin its wheels? Have I perhaps trashed malloc's heap list? Very likely. If you have the source code for malloc(), you might find that it is set up so that when compiled with -Ddebug it checks its arena every time it's invoked. Turning on this debugging check will often cause an early abort of the program not far from where the heap is being corrupted.