summaryrefslogtreecommitdiffstats
path: root/sys
diff options
context:
space:
mode:
authorrwatson <rwatson@FreeBSD.org>2005-01-22 21:14:21 +0000
committerrwatson <rwatson@FreeBSD.org>2005-01-22 21:14:21 +0000
commit57c91a09d8922106e5393b74c93003e798e2df5d (patch)
treed0c4a66ad4b9f373acc3964cbdaac88a09cfd1c9 /sys
parent822cad40f8527cf77451023f5b4b0e83d7c5a0ee (diff)
downloadFreeBSD-src-57c91a09d8922106e5393b74c93003e798e2df5d.zip
FreeBSD-src-57c91a09d8922106e5393b74c93003e798e2df5d.tar.gz
When DDB is not defined, don't implement witness_thread_has_locks() and
witness_proc_has_locks(), as they are unused, which results in a compiler error. This problem was introduced with the implementation of "show alllocks". Spotted by: Artem Kuchin <matrix at itlegion dot ru>
Diffstat (limited to 'sys')
-rw-r--r--sys/kern/subr_witness.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/sys/kern/subr_witness.c b/sys/kern/subr_witness.c
index 47f1b55..bc3ed26 100644
--- a/sys/kern/subr_witness.c
+++ b/sys/kern/subr_witness.c
@@ -1720,6 +1720,7 @@ witness_list_lock(struct lock_instance *instance)
instance->li_line);
}
+#ifdef DDB
static int
witness_thread_has_locks(struct thread *td)
{
@@ -1738,6 +1739,7 @@ witness_proc_has_locks(struct proc *p)
}
return (0);
}
+#endif
int
witness_list_locks(struct lock_list_entry **lock_list)
OpenPOWER on IntegriCloud