Commit Graph

12 Commits

Author SHA1 Message Date
David Anderson
5211b541d2 Final small changes for a new release.
Ensuring it builds where it should.
2014-02-01 08:06:09 -08:00
David Anderson
affafa89fb Removed trailing (and useless) whitespace from all the lines
containing it.  Many many files had such.
2014-01-29 15:02:07 -08:00
David Anderson
545d698072 Now using tsearch style calls with
dwarf_tsearch implementation.
Fixed a small memory curruption in dwarfdump2/print_pubnames.cc
Added tsearch directory with various sorts of tree searches
(all written from scratch, not copied from anywhere).
2014-01-29 11:41:39 -08:00
David Anderson
e0a6d32cb9 dwarfdump:
* dwarfdump.c: Change // comments to /* */ comments.
      * makename.c: Delete blank line and trailing space. Add cast
        so gcc -ansi compiles without complaint.
      * print_die.c, uri.c: Change // comments to /* */ comments.
      * tag_attr.c: Add getopt.h include so gcc -ansi compiles
        without complaint.
      * tag_tree.c: Add getopt.h and string.h include so gcc -ansi compiles
        without complaint. Add cast so strdup call to avoid warning.
      * addr_map.c: Add cast so strdup call does not cause warning gcc -ansi.
2014-01-10 15:23:29 -08:00
David Anderson
097c21f3fb Forgot to remove the implementation of addr_map_destroy()
from the ifndef HAVE_TSEARCH in dwarfdump/addrmap.c.
Now it is removed. The one under ifndef HAVE_TDESTROY
is the important one.
2013-02-04 10:45:35 -08:00
David Anderson
67c3df5e4d We separate tsearch() availability from tdestroy(). If
we have tsearch but not tdestroy() we use tsearch and let
it dwarfdump leak memory.  tdestroy() without tsearch()
makes no sense (how could that arise?).
We only have both in GNU libc.
dwarfdump2 has no such memory leak, it uses C++ facilities
instead of tsearch().
2013-02-03 16:05:20 -08:00
David Anderson
22cc16439d Update copyright year on a large number of files.
Everthing touched recently.
2012-11-17 13:31:29 -08:00
Carlos Alberto Enciso
82491fc2c7 Changes requested by David Anderson and described below. Also a general
change to make consistent use of 'if', 'for' and 'while'.

===================
dwarfdump.c lines 73-78  Any time an 'extern foo' appears in a .c or a .cc
file it represents a current or future error that cannot be easily detected
at compile time. Bad.

Instead, put print_attributes_encoding and current_cu_die_for_print_frames
declarations into appropriate .h files (possibly new one or ones?) and
include the header in each .c/.cc where it is needed. That prevents future
spelling errors from causing mysterious runtime failures due to argument
errors: the compiler will catch argument errors.

Now line 56-58 is special in that it refers to some windows thing, not
defined in  dwarfdump. So that one perhaps should or must stay as written.

===================
dwarfdump.c line 549: the variable 'bitmap' should be named something else.
bitmap is just too generic, not helpful to the reader. Easier for a
reviewer to see this sort of issue than the author :-)

Possibly local_section_bitmap? Somehow get 'section' in there in that
function-argument-name?

=======
dwarfdump.c: good catch on the indent errors in qsort_compare_compiler(),
I have no idea how I failed to run dicheck on that.

======
dwarfdump.c line 1043.  The 'Just for the moment' comment is odd. What
does that mean?  Why 'for the moment'? I am not going to try to guess
why you did that, but it has to be somehow wrong?
Either the code or the comment?

========
dwarfdump.c line 1162.  The comment says do not do reloc_flag = TRUE
yet you added exactly that!  Yikes! I don't know what to do about
this, but something has to change. Comment or statement. Can we detect
non-elf somehow? We probably already do, but...

===================
dwarfdump.c line 1630. Oops. Good catch on removing the mistaken extra
break;
2012-11-01 12:35:57 +00:00
David Anderson
f4b910cb6d Removed a debug printf that I left in accidentally (dwarfdump/addrmap.c). 2011-09-08 17:03:17 -07:00
David Anderson
4c2698d0d0 We were not correctly deleting all the tsearch data (used in
print_frames.c). Now we are.
2011-09-08 15:50:27 -07:00
David Anderson
7647aaeca8 Everything changed. New indentation. Many new DWARF correctness
tests.  New options.   Error summaries reported by compiler name.
2011-03-29 13:43:05 -07:00
David Anderson
637442ea0b Initial commit. Content is the libdwarf-20110113.tar.gz
last-released-libdwarf and dwarfdump.
2011-03-19 11:38:11 -07:00