[BACK]Return to nm.c CVS log [TXT][DIR] Up to [local] / src / usr.bin / nm

Diff for /src/usr.bin/nm/nm.c between version 1.43 and 1.44

version 1.43, 2015/04/08 04:23:15 version 1.44, 2015/04/09 04:46:18
Line 710 
Line 710 
                 (void)printf("\n%s:\n", name);                  (void)printf("\n%s:\n", name);
   
         /* print out symbols */          /* print out symbols */
         for (i = 0; i < nnames; i++) {          for (i = 0; i < nnames; i++)
                 if (show_extensions && snames[i] != names &&  
                     SYMBOL_TYPE((snames[i] -1)->n_type) == N_INDR)  
                         continue;  
                 print_symbol(name, snames[i]);                  print_symbol(name, snames[i]);
         }  
   
         free(snames);          free(snames);
         free(names);          free(names);
Line 745 
Line 741 
          */           */
         if (!print_only_undefined_symbols) {          if (!print_only_undefined_symbols) {
                 /* print symbol's value */                  /* print symbol's value */
                 if (SYMBOL_TYPE(sym->n_type) == N_UNDF ||                  if (SYMBOL_TYPE(sym->n_type) == N_UNDF)
                     (show_extensions && SYMBOL_TYPE(sym->n_type) == N_INDR &&  
                     sym->n_value == 0))  
                         (void)printf("        ");                          (void)printf("        ");
                 else                  else
                         (void)printf("%08lx", sym->n_value);                          (void)printf("%08lx", sym->n_value);
Line 759 
Line 753 
                         (void)printf(" %c ", typeletter(sym));                          (void)printf(" %c ", typeletter(sym));
         }          }
   
         if (SYMBOL_TYPE(sym->n_type) == N_INDR && show_extensions)          (void)puts(symname(sym));
                 printf("%s -> %s\n", symname(sym), symname(sym+1));  
         else  
                 (void)puts(symname(sym));  
 }  }
   
 /*  /*
Line 796 
Line 787 
                 return(ext? 'F' : 'W');                  return(ext? 'F' : 'W');
         case N_TEXT:          case N_TEXT:
                 return(ext? 'T' : 't');                  return(ext? 'T' : 't');
         case N_INDR:  
                 return(ext? 'I' : 'i');  
         case N_SIZE:          case N_SIZE:
                 return(ext? 'S' : 's');                  return(ext? 'S' : 's');
         case N_UNDF:          case N_UNDF:

Legend:
Removed from v.1.43  
changed lines
  Added in v.1.44