summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorcedric <cedric@openbsd.org>2003-02-04 12:10:02 +0000
committercedric <cedric@openbsd.org>2003-02-04 12:10:02 +0000
commitcb213333fc6d97fbdc5b5af1abe46da7719e3948 (patch)
treee32617a35d8c43bb97e48339e230968a24e3cb8e
parentturns out that was theo quoting someone, so it has no place here... bummer. (diff)
downloadwireguard-openbsd-cb213333fc6d97fbdc5b5af1abe46da7719e3948.tar.xz
wireguard-openbsd-cb213333fc6d97fbdc5b5af1abe46da7719e3948.zip
Cleanup buffer before reuse. Consistency + defensive programming.
-rw-r--r--sbin/pfctl/pfctl_table.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/sbin/pfctl/pfctl_table.c b/sbin/pfctl/pfctl_table.c
index 9daade3e392..41d0a4008b7 100644
--- a/sbin/pfctl/pfctl_table.c
+++ b/sbin/pfctl/pfctl_table.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: pfctl_table.c,v 1.31 2003/02/03 14:51:36 cedric Exp $ */
+/* $OpenBSD: pfctl_table.c,v 1.32 2003/02/04 12:10:02 cedric Exp $ */
/*
* Copyright (c) 2002 Cedric Berger
@@ -618,6 +618,7 @@ pfctl_define_table(char *name, int flags, int addrs, int noaction)
exit(1);
}
}
+ bzero(buffer.addrs, size * sizeof(buffer.addrs[0]));
size = 0;
}