This is the mail archive of the gdb@sources.redhat.com mailing list for the GDB project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: problem setting displays


>That's not how you do it.  You run until you are in MAIN__ and "display
>x".  Does that work?






No. The session that I showed only halted in MAIN__, so your condition was
satisfied and none of the displays that I tried to set were accepted.
Moreover, when I asked gdb to

   display MAIN__::i
   display MAIN__::x

before I said

   run

then all went ok. I had my watches every time gdb halted. As you may have
seen, no new watches were accepted once I commanded gdb to run. On 5.2.1 I
could get the watches after I reloaded the executable. On the Linux box
with gdb 5.0.x this did not work.

How can I have the value of a variable printed just once when program
execution halts? This instead of using "display". Maybe I could use such a
command. Would mean that I have to call all variables that I want to watch
every time the program halts, but until so far the 'display' command does
not seem to work.

Arjan


Arjan van Dijk
Institute for Marine and Atmospheric Research Utrecht
Faculty of Physics and Astronomy
Utrecht University
Princetonplein 5
NL - 3584 CC  Utrecht
The Netherlands

phone: +31 30 2532815
fax:   +31 30 2543163
e-mail: mailto:A.vanDijk@phys.uu.nl
homepage: http://www.phys.uu.nl/~vndijk



Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]