summaryrefslogtreecommitdiff
path: root/sys/compat/common/vfs_syscalls_12.c
diff options
context:
space:
mode:
Diffstat (limited to 'sys/compat/common/vfs_syscalls_12.c')
-rw-r--r--sys/compat/common/vfs_syscalls_12.c6
1 files changed, 4 insertions, 2 deletions
diff --git a/sys/compat/common/vfs_syscalls_12.c b/sys/compat/common/vfs_syscalls_12.c
index 4ec2f1be974..7ff5e471914 100644
--- a/sys/compat/common/vfs_syscalls_12.c
+++ b/sys/compat/common/vfs_syscalls_12.c
@@ -1,4 +1,4 @@
-/* $NetBSD: vfs_syscalls_12.c,v 1.37 2019/01/27 02:08:39 pgoyette Exp $ */
+/* $NetBSD: vfs_syscalls_12.c,v 1.37.4.1 2022/08/03 11:11:31 martin Exp $ */
/*
* Copyright (c) 1989, 1993
@@ -37,7 +37,7 @@
*/
#include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: vfs_syscalls_12.c,v 1.37 2019/01/27 02:08:39 pgoyette Exp $");
+__KERNEL_RCSID(0, "$NetBSD: vfs_syscalls_12.c,v 1.37.4.1 2022/08/03 11:11:31 martin Exp $");
#if defined(_KERNEL_OPT)
#include "opt_compat_netbsd.h"
@@ -82,6 +82,7 @@ void
compat_12_stat_conv(const struct stat *st, struct stat12 *ost)
{
+ memset(ost, 0, sizeof(*ost));
ost->st_dev = st->st_dev;
ost->st_ino = st->st_ino;
ost->st_mode = st->st_mode & 0xffff;
@@ -201,6 +202,7 @@ again:
off += reclen;
continue;
}
+ memset(&idb, 0, sizeof(idb));
if (bdp->d_namlen >= sizeof(idb.d_name))
idb.d_namlen = sizeof(idb.d_name) - 1;
else