Show
Ignore:
Timestamp:
10/12/09 22:59:21 (3 years ago)
Author:
H. Peter Anvin <hpa@…>
Children:
c45ffb669e96ed42d563831d13f3d113f7e18ebf
Parents:
fee688790af77e282a3d04c9fb061089ec16a502
git-committer:
H. Peter Anvin <hpa@zytor.com> / 2009-10-12T15:59:21Z-0700
Message:

mboot: correct the detection of the multiboot header

Correct the detection of the multiboot header. The logic for
when the header extends past the file was backwards, which broke
non-ELF multiboot kernels completely. Apparently they are few and far
between.

Reported-by: Klaus T. <nightos@…>
Signed-off-by: H. Peter Anvin <hpa@…>

Files:
1 modified

Legend:

Unmodified
Added
Removed
  • com32/mboot/map.c

    rfd0064 r3d6f51  
    128128            mbh_len = 12; 
    129129 
    130         if (i + mbh_len < len) 
     130        if (i + mbh_len > len) 
    131131            mbh_len = 0;        /* Invalid... */ 
    132132        else