Implement pahole-like 'ptype /o' option
[deliverable/binutils-gdb.git] / gdb / linespec.c
index e9664a0f316ba4c50c314bd83ba6c9efdb8cd8de..8c36f2a1a2bae1c006298d87d302a30b33f4f07d 100644 (file)
@@ -3113,7 +3113,6 @@ linespec_complete (completion_tracker &tracker, const char *text,
         the ':', then complete_linespec_component won't try to
         complete on source filenames.  */
 
-      const char *text = parser.completion_word;
       const char *word = parser.completion_word;
 
       complete_linespec_component (&parser, tracker,
@@ -4159,7 +4158,6 @@ find_label_symbols (struct linespec_state *self,
 {
   int ix;
   const struct block *block;
-  struct symbol *sym;
   struct symbol *fn_sym;
   VEC (symbolp) *result = NULL;
 
@@ -4367,9 +4365,10 @@ minsym_found (struct linespec_state *self, struct objfile *objfile,
       sal.objfile = objfile;
       sal.pc = MSYMBOL_VALUE_ADDRESS (objfile, msymbol);
       sal.pspace = current_program_space;
-      sal.section = MSYMBOL_OBJ_SECTION (objfile, msymbol);
     }
 
+  sal.section = MSYMBOL_OBJ_SECTION (objfile, msymbol);
+
   if (maybe_add_address (self->addr_set, objfile->pspace, sal.pc))
     add_sal_to_sals (self, result, &sal, MSYMBOL_NATURAL_NAME (msymbol), 0);
 }
This page took 0.026378 seconds and 4 git commands to generate.