summaryrefslogtreecommitdiff
path: root/usr.sbin
diff options
context:
space:
mode:
authorRyan Thomas McBride <mcbride@cvs.openbsd.org>2003-12-27 19:50:48 +0000
committerRyan Thomas McBride <mcbride@cvs.openbsd.org>2003-12-27 19:50:48 +0000
commitc29344868059523df6f7b2f02b1a2fb4f9f12520 (patch)
tree414001db460675dc2f48680d12f2835bfee6097f /usr.sbin
parent52fc07a2a32a001368662e9d54b317f523dd3c5f (diff)
Zero out the pf_state struct before filling it with data from the
pfsync_state struct.
Diffstat (limited to 'usr.sbin')
-rw-r--r--usr.sbin/tcpdump/print-pfsync.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/usr.sbin/tcpdump/print-pfsync.c b/usr.sbin/tcpdump/print-pfsync.c
index 3585f8b016c..3d8dc3c7861 100644
--- a/usr.sbin/tcpdump/print-pfsync.c
+++ b/usr.sbin/tcpdump/print-pfsync.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: print-pfsync.c,v 1.15 2003/12/19 23:13:08 mcbride Exp $ */
+/* $OpenBSD: print-pfsync.c,v 1.16 2003/12/27 19:50:47 mcbride Exp $ */
/*
* Copyright (c) 2002 Michael Shalayeff
@@ -28,7 +28,7 @@
#ifndef lint
static const char rcsid[] =
- "@(#) $Header: /cvs/OpenBSD/src/usr.sbin/tcpdump/print-pfsync.c,v 1.15 2003/12/19 23:13:08 mcbride Exp $";
+ "@(#) $Header: /cvs/OpenBSD/src/usr.sbin/tcpdump/print-pfsync.c,v 1.16 2003/12/27 19:50:47 mcbride Exp $";
#endif
#include <sys/param.h>
@@ -132,6 +132,7 @@ pfsync_print(struct pfsync_header *hdr, int len)
i <= hdr->count && i * sizeof(*s) <= len; i++, s++) {
struct pf_state st;
+ bzero(&st, sizeof(st));
st.id = s->id;
pf_state_host_ntoh(&s->lan, &st.lan);
pf_state_host_ntoh(&s->gwy, &st.gwy);