summaryrefslogtreecommitdiffstats
path: root/sys/kern/subr_bus.c
diff options
context:
space:
mode:
authornjl <njl@FreeBSD.org>2005-05-20 05:04:22 +0000
committernjl <njl@FreeBSD.org>2005-05-20 05:04:22 +0000
commit9ab8d98ce568fc756b4d0a97f73188f2c593e49e (patch)
tree31206b66d860791dc40ccecc90058b86117a3d27 /sys/kern/subr_bus.c
parentd8af4c8b76742ac9db58b0e960129399e40ac535 (diff)
downloadFreeBSD-src-9ab8d98ce568fc756b4d0a97f73188f2c593e49e.zip
FreeBSD-src-9ab8d98ce568fc756b4d0a97f73188f2c593e49e.tar.gz
Document that the returned pointer should be freed even if the number
of items returned is 0.
Diffstat (limited to 'sys/kern/subr_bus.c')
-rw-r--r--sys/kern/subr_bus.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/sys/kern/subr_bus.c b/sys/kern/subr_bus.c
index 3f2e477..1d7f3eb 100644
--- a/sys/kern/subr_bus.c
+++ b/sys/kern/subr_bus.c
@@ -1098,7 +1098,7 @@ devclass_get_softc(devclass_t dc, int unit)
* An array containing a list of all the devices in the given devclass
* is allocated and returned in @p *devlistp. The number of devices
* in the array is returned in @p *devcountp. The caller should free
- * the array using @c free(p, M_TEMP).
+ * the array using @c free(p, M_TEMP), even if @p *devcountp is 0.
*
* @param dc the devclass to examine
* @param devlistp points at location for array pointer return
OpenPOWER on IntegriCloud