Marco Gerards wrote:
Vincent Guffens <[EMAIL PROTECTED]> writes:


it looks like the problem is gone. I changed the way I allocate the
memory to hold a block. I changed from:

int load_block ()
        char * p = (char *) grub_malloc(len*sizeof(char));

to

int load_block ()
        char * p;
[...]
p = (char *) grub_malloc(len*sizeof(char));


This code is just the same.  I think the problem is still there but
just does not show up anymore.  I have seen a similar error before,
but I did not have the time to debug it.

Indead the problem is still there. It is now possible to do something like:

        grub> ifconfig
        [...]
        grub> loopback lo (nd)tfile
        [...]
        grub> ls (lo)/
        [...]
        grub> cat (lo)/file.txt
        [...]
        

I have tested three different card: Tulip, e1000, nforce2 as well as three compilers: gcc-2.95, gcc-3.0, gcc-3.3 However, the memory problem is still there, and I have no idea where it comes from. It varies depending on the compiler, the optimization flag, and some very small changes in the code. But it is always possible to find one combination of these for which the problem appears after loading a linux kernel or after the command boot or after a cat of a text file in the loopback device.



--
                                Vincent Guffens
                                PhD Student UCL/CESAME
                                tel:   +32 10 47 80 30
Value your freedom, or you will lose it, teaches history.
"Don't bother us with politics," respond those who don't want to learn.
                -- Richard M. Stallman


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

Reply via email to