fix the wrong checks in memcheck.

This commit is contained in:
okuji 1999-10-20 07:50:31 +00:00
parent 19c9df87bc
commit 08ba682d78
3 changed files with 8 additions and 3 deletions

View file

@ -1,3 +1,8 @@
1999-10-20 OKUJI Yoshinori <okuji@kuicr.kyoto-u.ac.jp>
* stage2/char_io.c (memcheck): Fix the checks: "<=" -> "<".
Reported by Mike Hicks <hick0088@umn.edu>.
1999-10-19 OKUJI Yoshinori <okuji@kuicr.kyoto-u.ac.jp>
* stage2/builtins.c (find_func): New function.

View file

@ -100,7 +100,6 @@ Part I: The Tutorial Manual
* Installation::
* Boot::
* Configuration::
* FAQ::
Part II: The User Reference Manual
@ -125,6 +124,7 @@ Part III: The Programmer Reference Manual
Appendices and Indices
* FAQ::
* Obtaining and Building GRUB::
* Reporting Bugs::
* Index::

View file

@ -833,9 +833,9 @@ memcheck (int addr, int len)
if ((addr < RAW_ADDR (0x1000))
|| (addr < RAW_ADDR (0x100000)
&& RAW_ADDR (mbi.mem_lower * 1024) <= (addr + len))
&& RAW_ADDR (mbi.mem_lower * 1024) < (addr + len))
|| (addr >= RAW_ADDR (0x100000)
&& RAW_ADDR (mbi.mem_upper * 1024) <= ((addr - 0x100000) + len)))
&& RAW_ADDR (mbi.mem_upper * 1024) < ((addr - 0x100000) + len)))
errnum = ERR_WONT_FIT;
return ! errnum;