bug-gdb
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Dereferencing Uninitialized Pointers


From: Steve Strobel
Subject: Dereferencing Uninitialized Pointers
Date: Fri, 26 Mar 2004 10:20:54 -0700

I am trying to debug a program that has structures containing char pointers (on 
a Motorola Coldfire 5272 processor, using a BDM connection).  Sometimes those 
pointers point to invalid memory addresses, addresses that cause a bus fault 
when dereferenced.  I am unable to print or display those structures because of 
the bus fault;  GDB doesn't continue printing the other stucture members after 
such a fault.  I can display individual members of the structure, but that is 
more work to set up.  I can think of several ways to avoid this problem; there 
may be others as well.  Is there a way to make GDB:

- continue printing the rest of a structure after a bus fault?
- understand that only certain memory regions are valid, such that it 
  won't try to access anything outside of those regions?
- stop automatically dereferencing char pointers?

Thanks for your help,

Steve
---
Steve Strobel
Link Communications, Inc.
1035 Cerise Rd
Billings, MT 59101-7378
(406) 245-5002 ext 102
(406) 245-4889 (fax)
WWW: http://www.link-comm.com
MailTo:address@hidden





reply via email to

[Prev in Thread] Current Thread [Next in Thread]