mirror of
https://github.com/bminor/binutils-gdb.git
synced 2025-12-28 18:10:46 +00:00
Fix some gcc -Wall warnings:
* cg_arcs.c (num_cycles): Change to unsigned int. (numarcs): Likewise. (arc_add): Change maxarcs to unsigned int. (cg_assemble): Change index to unsigned int. * cg_arcs.h (num_cycles, numarcs): Update declarations. * cg_print.c (cg_print): Change index to unsigned int. (cg_print_index): Change index, nnames, todo, i, and j to unsigned int. (cg_print_file_ordering): Change symbol_count and index2 to unsigned int. * core.c (symbol_map_count): Change to unsigned int. (core_create_function_syms): Change j to unsigned int. (core_create_line_syms): Add cast to avoid warning. * hist.c (hist_assign_samples): Change j to unsigned int. (hist_print): Change index to unsigned i nt. Add cast to avoid warning. * sym_ids.c (parse_spec): Add casts to avoid warning. * symtab.c (symtab_finalize): Change j to unsigned int. (sym_lookup): Update printf format strings. * symtab.h (Sym_Table): Change len to unsigned int. * tahoe.c (tahoe_reladdr): Add casts to avoid warnings.
This commit is contained in:
@@ -497,7 +497,7 @@ DEFUN (print_line, (np), Sym * np)
|
||||
void
|
||||
DEFUN (cg_print, (timesortsym), Sym ** timesortsym)
|
||||
{
|
||||
int index;
|
||||
unsigned int index;
|
||||
Sym *parent;
|
||||
|
||||
if (print_descriptions && bsd_style_output)
|
||||
@@ -557,7 +557,9 @@ DEFUN (cmp_name, (left, right), const PTR left AND const PTR right)
|
||||
void
|
||||
DEFUN_VOID (cg_print_index)
|
||||
{
|
||||
int index, nnames, todo, i, j, col, starting_col;
|
||||
unsigned int index;
|
||||
unsigned int nnames, todo, i, j;
|
||||
int col, starting_col;
|
||||
Sym **name_sorted_syms, *sym;
|
||||
const char *filename;
|
||||
char buf[20];
|
||||
@@ -1220,7 +1222,7 @@ DEFUN_VOID (cg_print_file_ordering)
|
||||
unsigned long scratch_arc_count, index;
|
||||
Arc **scratch_arcs;
|
||||
extern struct function_map *symbol_map;
|
||||
extern int symbol_map_count;
|
||||
extern unsigned int symbol_map_count;
|
||||
char *last;
|
||||
|
||||
scratch_arc_count = 0;
|
||||
@@ -1248,7 +1250,7 @@ DEFUN_VOID (cg_print_file_ordering)
|
||||
last = NULL;
|
||||
for (index = 0; index < symbol_map_count; index++)
|
||||
{
|
||||
int index2;
|
||||
unsigned int index2;
|
||||
|
||||
/* Don't bother searching if this symbol is the
|
||||
same as the previous one. */
|
||||
|
||||
Reference in New Issue
Block a user