From 85d14aaeb757550d63254fae5c0415b782e59a29 Mon Sep 17 00:00:00 2001 From: Alan Modra Date: Mon, 24 Aug 2020 13:06:46 +0930 Subject: [PATCH] PR26526, 5014c2d22b2 breaks compiling the Linux kernel for ARM PR 26526 * symbols.c (local_symbol_convert): Clear out xtra. --- gas/ChangeLog | 5 +++++ gas/symbols.c | 3 ++- 2 files changed, 7 insertions(+), 1 deletion(-) diff --git a/gas/ChangeLog b/gas/ChangeLog index 65b662dd142..1aa2792851d 100644 --- a/gas/ChangeLog +++ b/gas/ChangeLog @@ -1,3 +1,8 @@ +2020-08-24 Alan Modra + + PR 26526 + * symbols.c (local_symbol_convert): Clear out xtra. + 2020-08-21 Cooper Qu * config/tc-csky.c (CSKY_ISA_803R2): New. diff --git a/gas/symbols.c b/gas/symbols.c index 50b23d6ded6..04017b6744f 100644 --- a/gas/symbols.c +++ b/gas/symbols.c @@ -382,7 +382,8 @@ local_symbol_convert (void *sym) ++local_symbol_conversion_count; - xtra = (struct xsymbol *) obstack_alloc (¬es, sizeof *xtra); + xtra = (struct xsymbol *) obstack_alloc (¬es, sizeof (*xtra)); + memset (xtra, 0, sizeof (*xtra)); val = ent->lsy.value; ent->sy.x = xtra; -- 2.30.2