public inbox for glibc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug libc/31349] New: backtrace fails to look beyond null pointer when resolving stack (x86_64)
@ 2024-02-07  1:04 daniel at mariadb dot org
  2024-02-07  8:43 ` [Bug libc/31349] " fweimer at redhat dot com
                   ` (5 more replies)
  0 siblings, 6 replies; 7+ messages in thread
From: daniel at mariadb dot org @ 2024-02-07  1:04 UTC (permalink / raw)
  To: glibc-bugs

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

            Bug ID: 31349
           Summary: backtrace fails to look beyond null pointer when
                    resolving stack (x86_64)
           Product: glibc
           Version: 2.38
            Status: UNCONFIRMED
          Severity: normal
          Priority: P2
         Component: libc
          Assignee: unassigned at sourceware dot org
          Reporter: daniel at mariadb dot org
                CC: drepper.fsp at gmail dot com
  Target Milestone: ---

Created attachment 15352
  --> https://sourceware.org/bugzilla/attachment.cgi?id=15352&action=edit
bt.c

Using backtrace in a signal hander, a null pointer dereference is a typical
cause.

Backtrace stops at the null pointer and fails to show information of the higher
stack that caused it.

$ gcc -g -o /tmp/bt /tmp/bt.c

$ /tmp/bt
Obtained 2 stack frames.
/tmp/bt() [0x4011a2]
/lib64/libc.so.6(+0x3e9a0) [0x7f98f2b759a0]

Expected results closer to what gdb does:

$ gdb /tmp/bt
(gdb) bt
#0  0x0000000000000000 in ?? ()
#1  0x0000000000401235 in dummy_function () at /tmp/bt.c:35
#2  0x0000000000401250 in main () at /tmp/bt.c:42

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

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

end of thread, other threads:[~2024-02-07 10:54 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2024-02-07  1:04 [Bug libc/31349] New: backtrace fails to look beyond null pointer when resolving stack (x86_64) daniel at mariadb dot org
2024-02-07  8:43 ` [Bug libc/31349] " fweimer at redhat dot com
2024-02-07  8:58 ` daniel at mariadb dot org
2024-02-07 10:06 ` schwab@linux-m68k.org
2024-02-07 10:18 ` schwab@linux-m68k.org
2024-02-07 10:46 ` fweimer at redhat dot com
2024-02-07 10:54 ` schwab@linux-m68k.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).