aboutsummaryrefslogtreecommitdiff
path: root/sys/netgraph/ng_message.h
diff options
context:
space:
mode:
authorDavid Malone <dwmalone@FreeBSD.org>2000-11-18 15:17:43 +0000
committerDavid Malone <dwmalone@FreeBSD.org>2000-11-18 15:17:43 +0000
commit99cdf4ccb20964be566b457fdf69729b22b1d3d8 (patch)
treea6e1f0c867f08373c60669cd830de7a5c4680d51 /sys/netgraph/ng_message.h
parent238fe5f74d5db21ef7b65a64af54a30280153252 (diff)
downloadsrc-99cdf4ccb20964be566b457fdf69729b22b1d3d8.tar.gz
src-99cdf4ccb20964be566b457fdf69729b22b1d3d8.zip
Notes
Diffstat (limited to 'sys/netgraph/ng_message.h')
-rw-r--r--sys/netgraph/ng_message.h6
1 files changed, 2 insertions, 4 deletions
diff --git a/sys/netgraph/ng_message.h b/sys/netgraph/ng_message.h
index b84a6f72cf90..6b1b139201c1 100644
--- a/sys/netgraph/ng_message.h
+++ b/sys/netgraph/ng_message.h
@@ -292,10 +292,9 @@ struct typelist {
#define NG_MKMESSAGE(msg, cookie, cmdid, len, how) \
do { \
MALLOC((msg), struct ng_mesg *, sizeof(struct ng_mesg) \
- + (len), M_NETGRAPH, (how)); \
+ + (len), M_NETGRAPH, (how) | M_ZERO); \
if ((msg) == NULL) \
break; \
- bzero((msg), sizeof(struct ng_mesg) + (len)); \
(msg)->header.version = NG_VERSION; \
(msg)->header.typecookie = (cookie); \
(msg)->header.cmd = (cmdid); \
@@ -311,10 +310,9 @@ struct typelist {
#define NG_MKRESPONSE(rsp, msg, len, how) \
do { \
MALLOC((rsp), struct ng_mesg *, sizeof(struct ng_mesg) \
- + (len), M_NETGRAPH, (how)); \
+ + (len), M_NETGRAPH, (how) | M_ZERO); \
if ((rsp) == NULL) \
break; \
- bzero((rsp), sizeof(struct ng_mesg) + (len)); \
(rsp)->header.version = NG_VERSION; \
(rsp)->header.arglen = (len); \
(rsp)->header.token = (msg)->header.token; \