summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJohn Baldwin <jhb@FreeBSD.org>2006-04-21 20:40:43 +0000
committerJohn Baldwin <jhb@FreeBSD.org>2006-04-21 20:40:43 +0000
commitf9ab2f134fa9c830b948d7dd6e6960c294d7abca (patch)
tree7001118e98ebee8a93429b1ab5ea20a73f1069a4
parentcf93bc6617ff271462d454408d5027fd3d89234c (diff)
Notes
-rw-r--r--sys/kern/subr_sleepqueue.c1
-rw-r--r--sys/kern/subr_turnstile.c3
2 files changed, 3 insertions, 1 deletions
diff --git a/sys/kern/subr_sleepqueue.c b/sys/kern/subr_sleepqueue.c
index 5779fdf1e258..081c737a3406 100644
--- a/sys/kern/subr_sleepqueue.c
+++ b/sys/kern/subr_sleepqueue.c
@@ -907,6 +907,7 @@ found:
TAILQ_FOREACH(td, &sq->sq_blocked, td_slpq) {
db_printf("\t%p (tid %d, pid %d, \"%s\")\n", td,
td->td_tid, td->td_proc->p_pid,
+ td->td_name[0] != '\0' ? td->td_name :
td->td_proc->p_comm);
}
}
diff --git a/sys/kern/subr_turnstile.c b/sys/kern/subr_turnstile.c
index dd91b08e2cd0..16562f826a07 100644
--- a/sys/kern/subr_turnstile.c
+++ b/sys/kern/subr_turnstile.c
@@ -968,7 +968,8 @@ print_thread(struct thread *td, const char *prefix)
{
db_printf("%s%p (tid %d, pid %d, \"%s\")\n", prefix, td, td->td_tid,
- td->td_proc->p_pid, td->td_proc->p_comm);
+ td->td_proc->p_pid, td->td_name[0] != '\0' ? td->td_name :
+ td->td_proc->p_comm);
}
static void