A question about gdb script

Hui Zhu teawater@gmail.com
Fri Nov 27 08:05:00 GMT 2009


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.
>
>



More information about the Gdb mailing list