public inbox for elfutils@sourceware.org
 help / color / mirror / Atom feed
* [Bug tools/28032] New: eu-readelf --debug-dump=line stops after finding a table without line number statements.
@ 2021-06-30 16:25 vifoxa2454 at advew dot com
  2021-07-03 22:25 ` [Bug tools/28032] " mark at klomp dot org
  0 siblings, 1 reply; 2+ messages in thread
From: vifoxa2454 at advew dot com @ 2021-06-30 16:25 UTC (permalink / raw)
  To: elfutils-devel

https://sourceware.org/bugzilla/show_bug.cgi?id=28032

            Bug ID: 28032
           Summary: eu-readelf --debug-dump=line stops after finding a
                    table without line number statements.
           Product: elfutils
           Version: unspecified
            Status: UNCONFIRMED
          Severity: normal
          Priority: P2
         Component: tools
          Assignee: unassigned at sourceware dot org
          Reporter: vifoxa2454 at advew dot com
                CC: elfutils-devel at sourceware dot org
  Target Milestone: ---

We use an ABI dumper (https://github.com/lvc/abi-dumper) to make sure we don't
accidentally release binary incompatible changes by mistake. This tool uses
"eu-readelf --debug-dump=line" to get some of the information it needs.

In version 0.180 this worked fine, but when we upgraded to 0.182 it stopped
working. After some digging I found that a change in 0.181 caused the issue.

I found this link describing the change:
https://www.mail-archive.com/search?l=elfutils-devel@sourceware.org&q=subject:%22%5C%5BPATCH%5C%5D+readelf%5C%3A+It+is+not+an+error+if+there+are+no+line+number+statements%22&o=newest&f=1

Running "eu-readelf --debug-dump=line" on one of our shared libraries I get 92
tables on version 0.180, but only 6 tables on version 0.182. The last line in
the output of the 0.182 version is "No line number statements". The
corresponding table in version 0.180 says only "Line number statements:" and
then nothing. That table is very small (length 317, prologue length 311).

I believe that the bug is that the tool stops at this point instead of
continuing with the next table.

The problematic code (in src/readelf.c taken from version 0.185):

    if (linep == lineendp)
    {
        puts (_("\nNo line number statements."));
        return;
    }


If I comment out that block the tool work again for our use case.

Maybe some sort if if/else would be better?
I am not sure what would fit that code best as I have not done any deep diving
into it.

-- 
You are receiving this mail because:
You are on the CC list for the bug.

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2021-07-03 22:25 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-06-30 16:25 [Bug tools/28032] New: eu-readelf --debug-dump=line stops after finding a table without line number statements vifoxa2454 at advew dot com
2021-07-03 22:25 ` [Bug tools/28032] " mark at klomp dot org

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).