This is the mail archive of the
gdb-prs@sources.redhat.com
mailing list for the GDB project.
Re: c++/1210: Printing fails/aborts for some attributes (Cannot access memory at address)
- From: Daniel Jacobowitz <drow at mvista dot com>
- To: nobody at sources dot redhat dot com
- Cc: gdb-prs at sources dot redhat dot com,
- Date: 14 May 2003 14:58:01 -0000
- Subject: Re: c++/1210: Printing fails/aborts for some attributes (Cannot access memory at address)
- Reply-to: Daniel Jacobowitz <drow at mvista dot com>
The following reply was made to PR c++/1210; it has been noted by GNATS.
From: Daniel Jacobowitz <drow@mvista.com>
To: milan.schulte@offis.de
Cc: gdb-gnats@sources.redhat.com
Subject: Re: c++/1210: Printing fails/aborts for some attributes (Cannot access memory at address)
Date: Wed, 14 May 2003 10:50:50 -0400
On Wed, May 14, 2003 at 02:12:44PM -0000, milan.schulte@offis.de wrote:
>
> >Number: 1210
> >Category: c++
> >Synopsis: Printing fails/aborts for some attributes (Cannot access memory at address)
> >Confidential: no
> >Severity: serious
> >Priority: medium
> >Responsible: unassigned
> >State: open
> >Class: sw-bug
> >Submitter-Id: net
> >Arrival-Date: Wed May 14 14:18:00 UTC 2003
> >Closed-Date:
> >Last-Modified:
> >Originator: milan.schulte@offis.de
> >Release: unknown-1.0
> >Organization:
> >Environment:
>
> >Description:
> Using GDB 5.3 from console of DDD 3.3.1 to print the content of an object aborts at some attribute:
>
> (gdb) print (*this)
> $15 = (ControlEndCon [incomplete object]) {
> <ControlNode> = {
> <GraphNode> = {
> <Node> = {
> <Element> = {
> <Base> = {
> _vptr.Base = 0x85c5038
> }, <No data fields>},
> members of Node:
> myLocalSet = {Cannot access memory at address 0xfffffff4
> (gdb)
>
> The attribute myLocalSet is *not* a pointer. Printing the attribute with the following command works:
>
> (gdb) print (*this).myLocalSet
> $17 = (StorageUnitSet) {
> <Element> = {
> <Base> = {
> _vptr.Base = 0x859b9d0
> }, <No data fields>},
> <ComparableList<StorageUnit*>> = {
> <List<StorageUnit*>> = {
> <BasicType> = {
> _vptr.BasicType = 0x859b9d0
> },
> members of List<StorageUnit*>:
> mySize = 0,
> myIteratorCount = 0,
> myHead = 0x0,
> myTail = 0x0
> }, <No data fields>}, <No data fields>}
> (gdb)
>
> I'm using g++ (GCC) 3.3 and binutils 2.13.90.0.18 (i486-suse-linux) using BFD version 2.13.90.0.18
>
> The above works with the same source code using GCC 2.95.2, binutils 2.9.5, GDB 5.1.1, DDD 3.3.1.
>
> Any hints appreciated!
Could you please:
- Try a CVS snapshot of GDB
and/or
- Provide a small test case for the problem
?
--
Daniel Jacobowitz
MontaVista Software Debian GNU/Linux Developer