diff options
author | Josh Stone <jistone@redhat.com> | 2010-01-14 11:22:23 -0800 |
---|---|---|
committer | Josh Stone <jistone@redhat.com> | 2010-01-14 11:22:23 -0800 |
commit | 8aaef2fb30152bdc752b135bbeb1fb114b551694 (patch) | |
tree | a619ab7b5c17e1c047f1b6fa218fcf9417a8cb7c /dwflpp.cxx | |
parent | 025e49b203f4f4dc83e02e6440878c64ee616257 (diff) | |
download | systemtap-steved-8aaef2fb30152bdc752b135bbeb1fb114b551694.tar.gz systemtap-steved-8aaef2fb30152bdc752b135bbeb1fb114b551694.tar.xz systemtap-steved-8aaef2fb30152bdc752b135bbeb1fb114b551694.zip |
PR10467 cont'd: be tolerant of bad line numbers
If a line number is invalid for a source file, that should not be a
fatal error, as it may still be valid for some other matching source
file.
* dwflpp.cxx (dwflpp::iterate_over_srcfile_lines): Don't assert that the
line must be found, just break out quietly.
Diffstat (limited to 'dwflpp.cxx')
-rw-r--r-- | dwflpp.cxx | 7 |
1 files changed, 2 insertions, 5 deletions
@@ -1027,16 +1027,13 @@ dwflpp::iterate_over_srcfile_lines (char const * srcfile, ret = dwarf_getsrc_file (module_dwarf, srcfile, l, 0, &srcsp, &nsrcs); - if (line_type != WILDCARD && line_type != RANGE) - dwarf_assert ("dwarf_getsrc_file", ret); + if (ret != 0) /* tolerate invalid line number */ + break; if (line_type == WILDCARD || line_type == RANGE) { Dwarf_Addr line_addr; - if (ret != 0) /* tolerate invalid line number */ - break; - dwarf_lineno (srcsp [0], &lineno); /* Maybe lineno will exceed the input end */ if (line_type == RANGE && lineno > lines[1]) |