-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Vincent Guffens wrote:
> Vincent Pelletier wrote:
> It must be released by the one who called the malloc.

I don't see any good reason to forget - on kernel side - this chunk, as
we still keep the struct member in memory.
Anyway, I've done some other major changes to this patch, now the chunks
are a simple chained list. That prevents bugs like thinking the first
chunk is right after the last one in memory.
The new code is also much lighter on dprintf. I'll send a patch when
I'll have solved what I think is the last bug which only triggers on
x86: malloc returns sometime out of region pointers...

> grub_size_t n = ((size + GRUB_MM_ALIGN - 1) >> GRUB_MM_ALIGN_LOG2) + 1;
> which adds the extra block for the header.

I prefer relying on sizeof when it comes to allocating space instead of
such formula. If we ever change the struct size, it would break in a
strange way - like all memory allocation problems.

Vincent Pelletier
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.1 (GNU/Linux)

iD8DBQFC06YxFEQoKRQyjtURArzOAKCfGiIOe2uRirlH5UxRum2YzKwXXQCfdxua
ra/FrNuwvA+rG3GpWt7mtZw=
=UP6z
-----END PGP SIGNATURE-----

        

        
                
___________________________________________________________________________ 
Appel audio GRATUIT partout dans le monde avec le nouveau Yahoo! Messenger 
Téléchargez cette version sur http://fr.messenger.yahoo.com



_______________________________________________
Grub-devel mailing list
Grub-devel@gnu.org
http://lists.gnu.org/mailman/listinfo/grub-devel

Reply via email to