Clear all local_symbol.lsy_flags

Message ID 20200519011540.GK1088@bubble.grove.modra.org
State New
Headers show
Series
  • Clear all local_symbol.lsy_flags
Related show

Commit Message

* symbols.c (local_symbol_make): Init all of lsy_flags.


-- 
Alan Modra
Australia Development Lab, IBM

Patch

diff --git a/gas/symbols.c b/gas/symbols.c
index b1376a57b4..2fa7525173 100644
--- a/gas/symbols.c
+++ b/gas/symbols.c
@@ -327,14 +327,14 @@  local_symbol_make (const char *name, segT section, valueT val, fragS *frag)
 {
   const char *name_copy;
   struct local_symbol *ret;
+  struct symbol_flags flags = { .sy_local_symbol = 1, .sy_resolved = 0 };
 
   ++local_symbol_count;
 
   name_copy = save_symbol_name (name);
 
   ret = (struct local_symbol *) obstack_alloc (&notes, sizeof *ret);
-  ret->lsy_flags.sy_local_symbol = 1;
-  ret->lsy_flags.sy_resolved = 0;
+  ret->lsy_flags = flags;
   ret->lsy_name = name_copy;
   ret->lsy_section = section;
   local_symbol_set_frag (ret, frag);