This is the mail archive of the gdb@sourceware.org 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: A question about gdb script


Cool.

What I did is:
set $stop_recording_on_next_stop=0
set height 0

b functon_name
commands
record
set $stop_recording_on_next_stop=1
finish
end

define hook-stop
if $stop_recording_on_next_stop
set $stop_recording_on_next_stop=0
record save
record stop
c
end
end

It works very well.  When we done the record name issue, I will post it to wiki.

Thanks everyone.  :)

Hui

On Fri, Nov 27, 2009 at 02:24, Michael Snyder <msnyder@vmware.com> wrote:
> Hui Zhu wrote:
>
>> It looks not bad, but got a lot of:
>> ---Type <return> to continue, or q <return> to quit---q
>
> That can be fixed by saying "set height 0".
>
>> If you don't mind, I will post a patch to change each fprintf_filtered
>> in record.c to fprintf_unfiltered.
>
> No, I don't agree with that. ?If you do that, then user has
> no choice about pagination. ?"Set height" gives user a choice.
>
>


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