From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mailman by lists.gnu.org with archive (Exim 4.43) id 1DdFoR-0000qe-M6 for mharc-grub-devel@gnu.org; Tue, 31 May 2005 19:06:19 -0400 Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1DdFoK-0000n5-Ni for grub-devel@gnu.org; Tue, 31 May 2005 19:06:12 -0400 Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1DdFoE-0000ie-1E for grub-devel@gnu.org; Tue, 31 May 2005 19:06:09 -0400 Received: from [199.232.76.173] (helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1DdFoD-0000TK-9T for grub-devel@gnu.org; Tue, 31 May 2005 19:06:05 -0400 Received: from [212.43.237.68] (helo=kotoba.storever.com) by monty-python.gnu.org with esmtp (Exim 4.34) id 1DdFgr-0003iM-3I for grub-devel@gnu.org; Tue, 31 May 2005 18:58:29 -0400 Received: from ASSP-nospam (localhost [127.0.0.1]) by kotoba.storever.com (Postfix) with ESMTP id CCB22FF78295 for ; Wed, 1 Jun 2005 00:56:31 +0200 (CEST) Received: from 127.0.0.1 ([127.0.0.1] helo=ip6-localhost) by ASSP-nospam ; 31 May 05 22:56:31 -0000 From: "Yoshinori K. Okuji" Organization: enbug.org To: The development of GRUB 2 Date: Wed, 1 Jun 2005 00:56:30 +0200 User-Agent: KMail/1.7.2 References: <429C6B12.4080608@inma.ucl.ac.be> In-Reply-To: <429C6B12.4080608@inma.ucl.ac.be> MIME-Version: 1.0 Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: 7bit Content-Disposition: inline Message-Id: <200506010056.30654.okuji@enbug.org> Subject: Re: network support : memory management problem X-BeenThere: grub-devel@gnu.org X-Mailman-Version: 2.1.5 Precedence: list Reply-To: The development of GRUB 2 List-Id: The development of GRUB 2 List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 31 May 2005 23:06:15 -0000 On Tuesday 31 May 2005 15:48, Vincent Guffens wrote: > but depending on where in the code I free my data blocks, I sometimes > get a "free magic is broken" fatal error msg from grub_free(). Usually, it is due to a buffer overrun or underrun. > Does someone has an idea ? Is there some documentation available about > the mm in grub2 ? It is a typical (simple) malloc implementation. You can look at any textbook or web site about heap management to get ideas. The extensions are to always use magic to detect overrun / underrun, and to support multiple non-contiguous free regions. Have a look at the code. It is very small. Okuji