2009-08-30 Vladimir Serbinenko <phcoder@gmail.com>
* loader/i386/bsdXX.c (SUFFIX (grub_freebsd_load_elfmodule)): Fix loading of headers in some cases.
This commit is contained in:
parent
cc55302e00
commit
fe00f472fc
2 changed files with 11 additions and 6 deletions
|
@ -1,3 +1,8 @@
|
|||
2009-08-30 Vladimir Serbinenko <phcoder@gmail.com>
|
||||
|
||||
* loader/i386/bsdXX.c (SUFFIX (grub_freebsd_load_elfmodule)): Fix
|
||||
loading of headers in some cases.
|
||||
|
||||
2009-08-30 Robert Millan <rmh.grub@aybabtu.com>
|
||||
|
||||
* configure.ac: Bump version to 1.97~beta1.
|
||||
|
|
|
@ -197,15 +197,15 @@ SUFFIX (grub_freebsd_load_elfmodule) (grub_file_t file, int argc, char *argv[],
|
|||
if (curload < module + sizeof (e))
|
||||
curload = module + sizeof (e);
|
||||
|
||||
load (file, UINT_TO_PTR (module + e.e_shoff), e.e_shoff,
|
||||
load (file, UINT_TO_PTR (curload), e.e_shoff,
|
||||
e.e_shnum * e.e_shentsize);
|
||||
if (curload < module + e.e_shoff + e.e_shnum * e.e_shentsize)
|
||||
curload = module + e.e_shoff + e.e_shnum * e.e_shentsize;
|
||||
e.e_shoff = curload - module;
|
||||
curload += e.e_shnum * e.e_shentsize;
|
||||
|
||||
load (file, UINT_TO_PTR (module + e.e_phoff), e.e_phoff,
|
||||
load (file, UINT_TO_PTR (curload), e.e_phoff,
|
||||
e.e_phnum * e.e_phentsize);
|
||||
if (curload < module + e.e_phoff + e.e_phnum * e.e_phentsize)
|
||||
curload = module + e.e_phoff + e.e_phnum * e.e_phentsize;
|
||||
e.e_phoff = curload - module;
|
||||
curload += e.e_phnum * e.e_phentsize;
|
||||
|
||||
*kern_end = curload;
|
||||
|
||||
|
|
Loading…
Reference in a new issue