diff options
author | John Reiser <jreiser@BitWagon.com> | 2011-03-16 10:10:39 -0700 |
---|---|---|
committer | William Cohen <wcohen@redhat.com> | 2011-03-22 09:58:39 -0400 |
commit | 6690bc83a8a17405b1e678078f311f8a1677c24e (patch) | |
tree | 9e00337dff4606dd07e7089aed0ab02766669973 | |
parent | d74568b3585c7090ab25939f333b94d72ca3dd71 (diff) | |
download | memstomp-6690bc83a8a17405b1e678078f311f8a1677c24e.tar.gz memstomp-6690bc83a8a17405b1e678078f311f8a1677c24e.tar.xz memstomp-6690bc83a8a17405b1e678078f311f8a1677c24e.zip |
Use array notation in backtrace_symbols().
-rw-r--r-- | backtrace-symbols.c | 13 |
1 files changed, 5 insertions, 8 deletions
diff --git a/backtrace-symbols.c b/backtrace-symbols.c index ff91bea..9dd890c 100644 --- a/backtrace-symbols.c +++ b/backtrace-symbols.c @@ -80,9 +80,6 @@ static void load_funcs(void) #endif -/* 150 isn't special; it's just an arbitrary non-ASCII char value. */ -#define OPTION_DEMANGLER (150) - /* Read in the symbol table. */ static asymbol **slurp_symtab(bfd *const abfd) @@ -187,9 +184,9 @@ static void translate_addresses(bfd *abfd, char (*addr)[PTRSTR_LEN], int naddr) } #endif -static char ** translate_addresses_buf( +static char ** translate_addresses_vec( bfd *const abfd, - bfd_vma const *const addr, + bfd_vma const addr[], int naddr ) { @@ -257,7 +254,7 @@ static char ** translate_addresses_buf( static char **process_file( char const *const file_name, - bfd_vma const *const addr, + bfd_vma const addr[], int const naddr ) { @@ -280,7 +277,7 @@ static char **process_file( xexit(1); } - char **const ret_buf = translate_addresses_buf(abfd, addr, naddr); + char **const ret_buf = translate_addresses_vec(abfd, addr, naddr); bfd_close(abfd); return ret_buf; } @@ -317,7 +314,7 @@ static int find_matching_file(struct dl_phdr_info *const info, return 0; /* keep looking */ } -char **backtrace_symbols(void /*const*/ *const *const vector, int const length) +char **backtrace_symbols(void /*const*/ *const vector[], int const length) { /* discard calling function */ int const stack_depth = length - 1; |