PERFORCE change 49829 for review

John Baldwin jhb at FreeBSD.org
Wed Mar 31 14:22:39 PST 2004


On Sunday 28 March 2004 02:14 am, Marcel Moolenaar wrote:
> http://perforce.freebsd.org/chv.cgi?CH=49829
>
> Change 49829 by marcel at marcel_nfs on 2004/03/27 23:14:33
>
> 	Handle the T command. It's sent by gdb to check if a thread
> 	is alive. The command is sent prior to switching to that
> 	thread. This allows us to switch threads in gdb.
>
> Affected files ...
>
> .. //depot/projects/gdb/sys/gdb/gdb_main.c#10 edit
>
> Differences ...
>
> ==== //depot/projects/gdb/sys/gdb/gdb_main.c#10 (text+ko) ====
>
> @@ -193,6 +193,18 @@
>  			kdb_cpu_set_singlestep();
>  			return (1);
>  		}
> +		case 'T': {
> +			intmax_t tid;
> +			pid_t curtid;
> +			gdb_rx_varhex(&tid);
> +			curtid = kdb_thread->td_tid;
> +			if (kdb_set_thread(tid))
> +				gdb_tx_ok();
> +			else
> +				gdb_tx_err(ENOENT);
> +			kdb_set_thread(tid);
> +			break;
> +		}

Don't you want to switch back to curtid here?

-- 
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 p4-projects mailing list