diff options
author | 2016-05-21 19:06:15 +0000 | |
---|---|---|
committer | 2016-05-21 19:06:15 +0000 | |
commit | 86989bc3cc4958977b8860dec5fee7482e4137b7 (patch) | |
tree | 575001607646e6b58aecb7e9e9f6910a5f509a99 | |
parent | Remove the -x flag from mount_msdos and always assume the execute bit (diff) | |
download | wireguard-openbsd-86989bc3cc4958977b8860dec5fee7482e4137b7.tar.xz wireguard-openbsd-86989bc3cc4958977b8860dec5fee7482e4137b7.zip |
Zero op_name when we start enumerating properties such that we don't risk
skipping the properties of the root node when the lookup of random stack
garbage fails.
ok deraadt@
-rw-r--r-- | usr.sbin/eeprom/optree.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/usr.sbin/eeprom/optree.c b/usr.sbin/eeprom/optree.c index b77992c0f4c..f6cff9a7d3e 100644 --- a/usr.sbin/eeprom/optree.c +++ b/usr.sbin/eeprom/optree.c @@ -1,4 +1,4 @@ -/* $OpenBSD: optree.c,v 1.6 2009/01/14 21:05:53 fgsch Exp $ */ +/* $OpenBSD: optree.c,v 1.7 2016/05/21 19:06:15 kettenis Exp $ */ /* * Copyright (c) 2007 Federico G. Schwindt <fgsch@openbsd.org> @@ -111,6 +111,7 @@ op_nodes(int fd, int node, int depth) char op_name[BUFSIZE]; struct opiocdesc opio; + memset(op_name, 0, sizeof(op_name)); opio.op_nodeid = node; opio.op_buf = op_buf; opio.op_name = op_name; |