summaryrefslogtreecommitdiffstats
path: root/gnu
diff options
context:
space:
mode:
authordavidxu <davidxu@FreeBSD.org>2004-08-22 09:05:57 +0000
committerdavidxu <davidxu@FreeBSD.org>2004-08-22 09:05:57 +0000
commit7afd3579e83d23ffe69387db773514053ff74ff9 (patch)
tree07f04601e3ab6be38b1a04910e9613bf99ee7e7d /gnu
parentc29bdb1cc8f87daa0825fd1487e13c63356a92d5 (diff)
downloadFreeBSD-src-7afd3579e83d23ffe69387db773514053ff74ff9.zip
FreeBSD-src-7afd3579e83d23ffe69387db773514053ff74ff9.tar.gz
Fix comments, most are style fix.
Diffstat (limited to 'gnu')
-rw-r--r--gnu/usr.bin/gdb/libgdb/fbsd-threads.c32
1 files changed, 11 insertions, 21 deletions
diff --git a/gnu/usr.bin/gdb/libgdb/fbsd-threads.c b/gnu/usr.bin/gdb/libgdb/fbsd-threads.c
index 7fb5f52..93e019b 100644
--- a/gnu/usr.bin/gdb/libgdb/fbsd-threads.c
+++ b/gnu/usr.bin/gdb/libgdb/fbsd-threads.c
@@ -53,7 +53,7 @@ extern int child_suppress_run;
extern struct target_ops child_ops;
-/* This module's target vector. */
+/* This module's target vectors. */
static struct target_ops fbsd_thread_ops;
static struct target_ops fbsd_core_ops;
@@ -324,8 +324,6 @@ fbsd_thread_new_objfile (struct objfile *objfile)
{
td_err_e err;
- /* Don't attempt to use thread_db on targets which can not run
- (core files). */
if (objfile == NULL)
{
/* All symbols have been discarded. If the thread_db target is
@@ -342,9 +340,9 @@ fbsd_thread_new_objfile (struct objfile *objfile)
if (!child_suppress_run)
goto quit;
+ /* Nothing to do. The thread library was already detected and the
+ target vector was already activated. */
if (fbsd_thread_active)
- /* Nothing to do. The thread library was already detected and the
- target vector was already activated. */
goto quit;
/* Initialize the structure that identifies the child process. Note
@@ -484,14 +482,12 @@ fbsd_thread_resume (ptid_t ptid, int step, enum target_signal signo)
if (ret)
error (thread_db_err_str (ret));
- /*
- * For M:N thread, we need to tell UTS to set/unset single step
- * flag at context switch time, the flag will be written into
- * thread mailbox. This becauses some architecture may not have
- * machine single step flag in ucontext, so we put the flag in mailbox,
- * when the thread switches back, kse_switchin restores the single step
- * state.
- */
+ /* For M:N thread, we need to tell UTS to set/unset single step
+ flag at context switch time, the flag will be written into
+ thread mailbox. This becauses some architecture may not have
+ machine single step flag in ucontext, so we put the flag in mailbox,
+ when the thread switches back, kse_switchin restores the single step
+ state. */
ret = td_thr_sstep_p (&th, step);
if (ret)
error (thread_db_err_str (ret));
@@ -764,10 +760,8 @@ fbsd_thread_post_startup_inferior (ptid_t ptid)
{
if (fbsd_thread_present && !fbsd_thread_active)
{
- /*
- * The child process is now the actual multi-threaded
- * program. Snatch its process ID...
- */
+ /* The child process is now the actual multi-threaded
+ program. Snatch its process ID... */
proc_handle.pid = GET_PID (ptid);
td_ta_new_p (&proc_handle, &thread_agent);
fbsd_thread_activate();
@@ -777,10 +771,6 @@ fbsd_thread_post_startup_inferior (ptid_t ptid)
static void
fbsd_thread_mourn_inferior (void)
{
- /*
- * Forget about the child's process ID. We shouldn't need it
- * anymore.
- */
if (fbsd_thread_active)
fbsd_thread_deactivate ();
OpenPOWER on IntegriCloud