aboutsummaryrefslogtreecommitdiff
path: root/sys/kern/subr_counter.c
diff options
context:
space:
mode:
authorGleb Smirnoff <glebius@FreeBSD.org>2016-03-15 00:21:32 +0000
committerGleb Smirnoff <glebius@FreeBSD.org>2016-03-15 00:21:32 +0000
commit1d52250154b93079b8fe87038ead2d740916bb41 (patch)
treec4957f034ab42c94b661043901b6cfd102434c7b /sys/kern/subr_counter.c
parentdbfd87087bf7ea38323ee5aa24e26483eea30117 (diff)
downloadsrc-1d52250154b93079b8fe87038ead2d740916bb41.tar.gz
src-1d52250154b93079b8fe87038ead2d740916bb41.zip
Free the temporary buffer in sysctl_handle_counter_u64_array().
Submitted by: mjg
Notes
Notes: svn path=/head/; revision=296883
Diffstat (limited to 'sys/kern/subr_counter.c')
-rw-r--r--sys/kern/subr_counter.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/sys/kern/subr_counter.c b/sys/kern/subr_counter.c
index bade8b8fb2ac..5149f2d2a37d 100644
--- a/sys/kern/subr_counter.c
+++ b/sys/kern/subr_counter.c
@@ -106,6 +106,7 @@ sysctl_handle_counter_u64_array(SYSCTL_HANDLER_ARGS)
out[i] = counter_u64_fetch(((counter_u64_t *)arg1)[i]);
error = SYSCTL_OUT(req, out, arg2 * sizeof(uint64_t));
+ free(out, M_TEMP);
if (error || !req->newptr)
return (error);