mirror of
https://sourceware.org/git/binutils-gdb.git
synced 2024-11-23 10:03:47 +08:00
gas/ELF: also reject merge entity size being zero
This won't have any useful effect, so is at best marginally less bogus than a negative value. The change actually points out a flawed (for Arm) testcase: @ is a comment character there.
This commit is contained in:
parent
76445f36a2
commit
d5cbf916be
@ -8,5 +8,5 @@
|
|||||||
resulting size was gigantic and consequently the library quickly ran out
|
resulting size was gigantic and consequently the library quickly ran out
|
||||||
of memory. */
|
of memory. */
|
||||||
|
|
||||||
.section .debug_str,"MS",@progbits,1
|
.section .debug_str,"MS",%progbits,1
|
||||||
.string "ZLIB_VER_SUBREVISION 0"
|
.string "ZLIB_VER_SUBREVISION 0"
|
||||||
|
@ -1327,7 +1327,7 @@ obj_elf_section (int push)
|
|||||||
goto fetch_entsize;
|
goto fetch_entsize;
|
||||||
entsize = get_absolute_expression ();
|
entsize = get_absolute_expression ();
|
||||||
SKIP_WHITESPACE ();
|
SKIP_WHITESPACE ();
|
||||||
if (entsize < 0)
|
if (entsize <= 0)
|
||||||
{
|
{
|
||||||
as_warn (_("invalid merge entity size"));
|
as_warn (_("invalid merge entity size"));
|
||||||
attr &= ~SHF_MERGE;
|
attr &= ~SHF_MERGE;
|
||||||
|
Loading…
Reference in New Issue
Block a user