diff options
author | glebius <glebius@FreeBSD.org> | 2015-02-13 23:57:20 +0000 |
---|---|---|
committer | glebius <glebius@FreeBSD.org> | 2015-02-13 23:57:20 +0000 |
commit | a9731f30c8eef0c07813f21884d05d8f12dc1dd9 (patch) | |
tree | 763f08ef2ab4ed8d8c0c727769cfc6482949f664 /usr.sbin/flowctl/flowctl.c | |
parent | 375a1b0d29b16252951e12bfab677805c00e93d4 (diff) | |
download | FreeBSD-src-a9731f30c8eef0c07813f21884d05d8f12dc1dd9.zip FreeBSD-src-a9731f30c8eef0c07813f21884d05d8f12dc1dd9.tar.gz |
Use less ugly code to allocate buffer of SORCVBUF_SIZE.
Diffstat (limited to 'usr.sbin/flowctl/flowctl.c')
-rw-r--r-- | usr.sbin/flowctl/flowctl.c | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/usr.sbin/flowctl/flowctl.c b/usr.sbin/flowctl/flowctl.c index 531b988..0c7539a 100644 --- a/usr.sbin/flowctl/flowctl.c +++ b/usr.sbin/flowctl/flowctl.c @@ -222,10 +222,12 @@ ctl_show(int argc, char **argv) static void do_show(int version, void (*func)(struct ngnf_show_header *)) { - struct ng_mesg ng_mesg[SORCVBUF_SIZE]; + char buf[SORCVBUF_SIZE]; + struct ng_mesg *ng_mesg; struct ngnf_show_header req, *resp; int token, nread; + ng_mesg = (struct ng_mesg *)buf; req.version = version; req.hash_id = req.list_id = 0; |