>>>>> Rogelio M Serrano writes:

105      if (type == KERNEL_TYPE_MULTIBOOT)
106        entry_addr = (entry_func) pu.elf->e_entry;
107      else
108        entry_addr = (entry_func) (pu.elf->e_entry & 0xFFFFFF);
109
110      if (((int) entry_addr) < 0x100000)
111        errnum = ERR_BELOW_1MB;

 RMS> in line 110 if my e_entry is 0xf0100000 we should not get an
 RMS> error right?  same with line 520: my p_addr this time is
 RMS> 0x100000

[...]

 RMS> am i getting the error at 111?

The problem I see is that the test at 110 looks like:

      if (((int) 0xf0100000) < 0x100000)

Try this on your own, and you'll see that the problem is the (int)
cast turning your large address into a negative number.  Perhaps a
better test would be:

      if (entry_addr < (entry_func) 0x100000)

Of course, this is all speculation, since I can't check the results
myself at the moment.

I hope this helps you,

-- 
 Gordon Matzigkeit <[EMAIL PROTECTED]>  //\ I'm a FIG (http://fig.org/)
Committed to freedom and diversity \//  Run Bash (http://fig.org/gnu/bash/)

_______________________________________________
Bug-grub mailing list
[EMAIL PROTECTED]
http://mail.gnu.org/mailman/listinfo/bug-grub

Reply via email to