BR3392439: make sure to update globalbits if appropriate

For some output types, the bit size, globalbits, follow the section
(segment); make sure we actually update it!

Signed-off-by: H. Peter Anvin <hpa@linux.intel.com>
This commit is contained in:
H. Peter Anvin 2017-09-27 14:22:16 -07:00
parent 5e03c443e4
commit e800127a46

View file

@ -229,7 +229,7 @@ bool process_directives(char *directive)
case D_SEGMENT: /* [SEGMENT n] */
case D_SECTION:
{
int sb;
int sb = globalbits;
int32_t seg = ofmt->section(value, pass2, &sb);
if (seg == NO_SEG) {
@ -238,6 +238,7 @@ bool process_directives(char *directive)
} else {
in_absolute = false;
location.segment = seg;
globalbits = sb;
}
break;
}