cvs commit: src/sys/ddb db_command.c db_output.c

John Baldwin jhb at FreeBSD.org
Mon Oct 3 08:14:52 PDT 2005


On Sunday 02 October 2005 06:57 pm, Olivier Houchard wrote:
> cognet      2005-10-02 22:57:31 UTC
>
>   FreeBSD src repository
>
>   Modified files:
>     sys/ddb              db_command.c db_output.c
>   Log:
>   - Call db_setup_paging() for traceall.
>   - Make it so one can't call db_setup_paging() if it has already been
> called before. traceall needs this, or else the db_setup_paging() call from
> db_trace_thread() will reset the printed line number, and override its
> argument.
>   This is not perfect for traceall, because even if one presses 'q' while
> in the middle of printing a backtrace it will finish printing the backtrace
> before exiting, as db_trace_thread() won't be notified it should stop, but
> it is hard to do better without reworking the pager interface a lot more.

Actually, traceall() can be fixed without too much difficulty.  Just adjust 
the API such that the MD function to trace a thread isn't the direct DDB 
function, but takes a pointer to the quit variable.  Then have traceall() 
pass in its quit variable and add a simple MI wrapper for the single trace 
case that passes in a local quit variable as well and move db_setup_pager() 
into that MI wrapper and out of the MD functions.

-- 
John Baldwin <jhb at FreeBSD.org>  <><  http://www.FreeBSD.org/~jhb/
"Power Users Use the Power to Serve"  =  http://www.FreeBSD.org


More information about the cvs-src mailing list