1
Fork 0
mirror of git://git.sv.gnu.org/emacs.git synced 2026-01-05 03:20:39 -08:00

(unexec): Round up section header offset to bss alignment

before deciding whether it's after the bss section.
This commit is contained in:
Richard M. Stallman 1996-06-24 19:54:38 +00:00
parent aa39a5ddc0
commit faee8ef030

View file

@ -767,7 +767,9 @@ unexec (new_name, old_name, data_start, bss_start, entry_address)
>= OLD_SECTION_H (old_bss_index-1).sh_offset)
NEW_SECTION_H (nn).sh_offset += new_data2_size;
#else
if (NEW_SECTION_H (nn).sh_offset >= new_data2_offset)
if (round_up (NEW_SECTION_H (nn).sh_offset,
OLD_SECTION_H (old_bss_index).sh_addralign)
>= new_data2_offset)
NEW_SECTION_H (nn).sh_offset += new_data2_size;
#endif
/* Any section that was originally placed after the section