Bug 860696 - GDB segfaults when stepping through a program
Summary: GDB segfaults when stepping through a program
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Red Hat Developer Toolset
Classification: Red Hat
Component: gdb
Version: DTS 1.1 RHEL 5
Hardware: ppc64
OS: Unspecified
unspecified
high
Target Milestone: beta2
: 1.1
Assignee: Jan Kratochvil
QA Contact: Martin Cermak
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2012-09-26 13:57 UTC by Marek Polacek
Modified: 2013-01-22 14:39 UTC (History)
5 users (show)

Fixed In Version: devtoolset-1.1-gdb-7.5.0.20120926-22.el5
Doc Type: Release Note
Doc Text:
No documentation needed
Clone Of:
Environment:
Last Closed: 2013-01-22 14:39:32 UTC
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Red Hat Product Errata RHEA-2013:0172 0 normal SHIPPED_LIVE new packages: devtoolset-1.1-gdb 2013-01-22 19:33:04 UTC

Description Marek Polacek 2012-09-26 13:57:25 UTC
# scl enable devtoolset-1.1 bash
# rpm -q devtoolset-1.1-gdb
devtoolset-1.1-gdb-7.5-20.el5
# gdb /bin/true -q -ex sta -ex 's 999999'
Reading symbols from /bin/true...Reading symbols from /usr/lib/debug/bin/true.debug...done.
done.
Temporary breakpoint 1 at 0x10000c38: file true.c, line 63.
Starting program: /bin/true 

Temporary breakpoint 1, main (argc=1, argv=0xffabf654) at true.c:63
63	  setlocale (LC_ALL, "");
Segmentation fault

When stepping manually:
(gdb) 
__ctype_b_loc () at ../include/ctype.h:34
34	  if (__builtin_expect (*u.tablep == NULL, 0))
(gdb) 
_nl_normalize_codeset (codeset=0xfff6fd2a "UTF-8", name_len=1) at l10nflist.c:341
341		if (isalpha ((unsigned char) codeset[cnt]))
(gdb) 
336	  for (cnt = 0; cnt < name_len; ++cnt)
(gdb) 
341		if (isalpha ((unsigned char) codeset[cnt]))
(gdb) 
336	  for (cnt = 0; cnt < name_len; ++cnt)
(gdb) 
345	  retval = (char *) malloc ((only_digit ? 3 : 0) + len + 1);
(gdb) 
Segmentation fault

With system gdb:

# gdb /bin/true -q -ex sta -ex 's 999999' -ex q
Reading symbols from /bin/true...Reading symbols from /usr/lib/debug/bin/true.debug...done.
done.
Temporary breakpoint 1 at 0x10000c38: file true.c, line 63.
Starting program: /bin/true 

Temporary breakpoint 1, main (argc=1, argv=0xffc2f8d4) at true.c:63
63	  setlocale (LC_ALL, "");

Program exited normally.

Seems this doesn't happen on RHEL6.

Comment 2 Jan Kratochvil 2012-09-26 16:59:52 UTC
[patch+7.5] Fix ppc32 7.5 stepping crash regression
http://sourceware.org/ml/gdb-patches/2012-09/msg00598.html

QA: New testfile: gdb.base/step-symless.exp

Comment 5 errata-xmlrpc 2013-01-22 14:39:32 UTC
Since the problem described in this bug report should be
resolved in a recent advisory, it has been closed with a
resolution of ERRATA.

For information on the advisory, and where to find the updated
files, follow the link below.

If the solution does not work for you, open a new bug report.

http://rhn.redhat.com/errata/RHEA-2013-0172.html


Note You need to log in before you can comment on or make changes to this bug.