public inbox for elfutils@sourceware.org
 help / color / mirror / Atom feed
From: "mark at klomp dot org" <sourceware-bugzilla@sourceware.org>
To: elfutils-devel@sourceware.org
Subject: [Bug libdw/31447] New: Provide a public debug section relocation function
Date: Sun, 03 Mar 2024 12:19:09 +0000	[thread overview]
Message-ID: <bug-31447-10460@http.sourceware.org/bugzilla/> (raw)

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

            Bug ID: 31447
           Summary: Provide a public debug section relocation function
           Product: elfutils
           Version: unspecified
            Status: NEW
          Severity: normal
          Priority: P2
         Component: libdw
          Assignee: unassigned at sourceware dot org
          Reporter: mark at klomp dot org
                CC: elfutils-devel at sourceware dot org
  Target Milestone: ---

When opening an ET_REL file with dwarf_begin no relocations are resolved and no
error checking is done if that is necessary. Causing some functions to produce
errors or wrong results (because an index is wrongly assumed to be zero).

When opening such a file through libdwfl we do resolve all cross-debug-section
relocations using __libdwfl_relocate.

It would be good to make this a public function. Maybe through libdwelf
dwelf_relocation_debug_sections (Elf *elf). So users can make sure ET_REL files
can be handled by libdw.

And maybe add a check/flag in dwarf_begin so an error can be produced if a
relocation value is needed for a correct result.

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

             reply	other threads:[~2024-03-03 12:19 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-03-03 12:19 mark at klomp dot org [this message]
2024-03-03 12:35 ` [Bug libdw/31447] " mark at klomp dot org
2024-03-21 14:19 ` dichen at redhat dot com
2024-05-12  7:29 ` dichen at redhat dot com
2024-05-12  9:06 ` mark at klomp dot org

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=bug-31447-10460@http.sourceware.org/bugzilla/ \
    --to=sourceware-bugzilla@sourceware.org \
    --cc=elfutils-devel@sourceware.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
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).