gdb: add target_ops::supports_displaced_step
[deliverable/binutils-gdb.git] / gas / symbols.c
index b1376a57b49584c648721bb4ad051ff96e57a20e..acf394330dfce03e213f3dc06e33d567e989bd5d 100644 (file)
@@ -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);
@@ -923,14 +923,12 @@ symbol_find_noref (const char *name, int noref)
        *copy++ = TOUPPER (c);
       *copy = '\0';
 
-      if (copy2 != NULL)
-       free (copy2);
+      free (copy2);
       copy = (char *) name;
     }
 
   result = symbol_find_exact_noref (name, noref);
-  if (copy != NULL)
-    free (copy);
+  free (copy);
   return result;
 }
 
This page took 0.023457 seconds and 4 git commands to generate.