Subject: gdb: Demangler crashes when debugging C++ code
Date: Thu, 04 Dec 2014 15:58:30 +0100
Package: gdb
Version: 7.7.1+dfsg-5
Severity: important
Tags: upstream
Dear Maintainer,
I noticed a bug in the C++ demangler of GDB 7.7, that causes it to segfault
when debugging certain binaries. GDB 7.4 in wheezy does not have this bug, so
downgrading helps in my case.
The bug is known upstream, but a fix has not been committed yet.
Please track upstream and provide a fixed version once it has been released.
Thank you.
The upstream bug is: https://sourceware.org/bugzilla/show_bug.cgi?id=17066
I noticed the bug when I ran into the following problem: https://bugreports.qt-
project.org/browse/QTCREATORBUG-12450
-- System Information:
Debian Release: jessie/sid
APT prefers testing
APT policy: (990, 'testing'), (900, 'stable'), (50, 'testing-updates'), (50, 'unstable'), (50, 'stable')
Architecture: amd64 (x86_64)
Foreign Architectures: i386
Kernel: Linux 3.16-2-amd64 (SMP w/4 CPU cores)
Locale: LANG=en_GB.UTF-8, LC_CTYPE=en_GB.UTF-8 (charmap=UTF-8)
Shell: /bin/sh linked to /bin/dash
Versions of packages gdb depends on:
ii libc6 2.19-13
ii libexpat1 2.1.0-6+b3
ii liblzma5 5.1.1alpha+20120614-2+b2
ii libncurses5 5.9+20140913-1
ii libpython2.7 2.7.8-11
ii libreadline6 6.3-8+b1
ii libtinfo5 5.9+20140913-1
ii zlib1g 1:1.2.8.dfsg-2+b1
Versions of packages gdb recommends:
ii gdbserver 7.7.1+dfsg-5
ii libc6-dbg [libc-dbg] 2.19-13
Versions of packages gdb suggests:
pn gdb-doc <none>
-- no debconf information
Acknowledgement sent
to Martin Read <[email protected]>:
Extra info received and forwarded to list. Copy sent to Héctor Orón Martínez <[email protected]>.
(Fri, 17 Nov 2017 10:36:03 GMT) (full text, mbox, link).
Subject: Re: gdb: Demangler crashes when debugging C++ code
Date: Fri, 17 Nov 2017 09:55:28 +0000
Package: gdb
Version: 7.12-6
Followup-For: Bug #772039
Dear Maintainer,
I have an example of a source tree which, its program having been built,
causes the GDB demangler to crash.
The program in question is a Doom WAD editing tool called SLADE, and the
source code can be found on github at:
https://github.com/sirjuddington/SLADE
The result of trying to debug this program is as follows:
--- begin crash transcript
mormegil@cocytus:~/games/wadediting$ gdb ./slade
GNU gdb (Debian 7.12-6) 7.12.0.20161007-git
Copyright (C) 2016 Free Software Foundation, Inc.
License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html>
This is free software: you are free to change and redistribute it.
There is NO WARRANTY, to the extent permitted by law. Type "show copying"
and "show warranty" for details.
This GDB was configured as "x86_64-linux-gnu".
Type "show configuration" for configuration details.
For bug reporting instructions, please see:
<http://www.gnu.org/software/gdb/bugs/>.
Find the GDB manual and other documentation resources online at:
<http://www.gnu.org/software/gdb/documentation/>.
For help, type "help".
Type "apropos word" to search for commands related to "word"...
Reading symbols from ./slade.../build/gdb-A87voC/gdb-7.12/gdb/cp-support.c:1600: demangler-warning: unable to demangle '_ZSt7forwardIRZN3sol15function_detail19overloaded_functionILi0EJPFSt6vectorIP7ArchiveSaIS5_EEbEZN3Lua25registerArchivesNamespaceERNS0_5stateEEUlvE_EEclEP9lua_StateEUlDpOT_E_EOT_RNSt16remove_referenceISM_E4typeE' (demangler failed with signal 11)
Unable to dump core, use `ulimit -c unlimited' before executing GDB next time.
/build/gdb-A87voC/gdb-7.12/gdb/cp-support.c:1615: demangler-warning: unable to demangle '_ZSt7forwardIRZN3sol15function_detail19overloaded_functionILi0EJPFSt6vectorIP7ArchiveSaIS5_EEbEZN3Lua25registerArchivesNamespaceERNS0_5stateEEUlvE_EEclEP9lua_StateEUlDpOT_E_EOT_RNSt16remove_referenceISM_E4typeE' (demangler failed with signal 11)
A problem internal to GDB has been detected,
further debugging may prove unreliable.
Quit this debugging session? (y or n)
--- end crash transcript
-- System Information:
Debian Release: 9.1
APT prefers stable
APT policy: (500, 'stable')
Architecture: amd64 (x86_64)
Foreign Architectures: i386
Kernel: Linux 4.9.0-4-amd64 (SMP w/4 CPU cores)
Locale: LANG=en_GB.UTF-8, LC_CTYPE=en_GB.UTF-8 (charmap=UTF-8), LANGUAGE=en_GB:en (charmap=UTF-8)
Shell: /bin/sh linked to /bin/dash
Init: systemd (via /run/systemd/system)
Versions of packages gdb depends on:
ii libbabeltrace-ctf1 1.5.1-1
ii libbabeltrace1 1.5.1-1
ii libc6 2.24-11+deb9u1
ii libexpat1 2.2.0-2+deb9u1
ii liblzma5 5.2.2-1.2+b1
ii libncurses5 6.0+20161126-1+deb9u1
ii libpython3.5 3.5.3-1
ii libreadline7 7.0-3
ii libtinfo5 6.0+20161126-1+deb9u1
ii zlib1g 1:1.2.8.dfsg-5
Versions of packages gdb recommends:
ii libc6-dbg [libc-dbg] 2.24-11+deb9u1
Versions of packages gdb suggests:
ii gdb-doc 7.12-2
ii gdbserver 7.12-6
-- no debconf information