Ensure that space allocated by assembler directives converts from an octet count to a byte count.

PR 26556
	* read.c (bss_alloc): Convert size parameter from octets to
	bytes.
This commit is contained in:
Nick Clifton 2020-09-18 13:28:46 +01:00
parent d0edc2b806
commit 5947daaf75
2 changed files with 7 additions and 1 deletions

View File

@ -1,3 +1,9 @@
2020-09-18 Tucker <tuckkern+sourceware@gmail.com>
PR 26556
* read.c (bss_alloc): Convert size parameter from octets to
bytes.
2020-09-17 Alan Modra <amodra@gmail.com>
* testsuite/gas/i386/i386.exp: Return early if not x86.

View File

@ -2547,7 +2547,7 @@ bss_alloc (symbolS *symbolP, addressT size, unsigned int align)
symbol_get_frag (symbolP)->fr_symbol = NULL;
symbol_set_frag (symbolP, frag_now);
pfrag = frag_var (rs_org, 1, 1, 0, symbolP, size, NULL);
pfrag = frag_var (rs_org, 1, 1, 0, symbolP, size * OCTETS_PER_BYTE, NULL);
*pfrag = 0;
#ifdef S_SET_SIZE