summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMartin Natano <natano@cvs.openbsd.org>2016-04-26 18:23:08 +0000
committerMartin Natano <natano@cvs.openbsd.org>2016-04-26 18:23:08 +0000
commit7ecc2d32b5303fb3f3bb05758293b256d481b603 (patch)
treef8b6b3b2c3f7b839760b9dd43d52610c44915268
parent3a7b92476632ebe12294f8d79d47e67bbd8639b3 (diff)
copy_statfs_info() is not only used by ufs, but by other filesystems too,
so make sure that all members of mp->mnt_stat.mount_info are copied. ok stefan
-rw-r--r--sys/kern/vfs_subr.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/sys/kern/vfs_subr.c b/sys/kern/vfs_subr.c
index d4579f3dfe0..71b4b7b1982 100644
--- a/sys/kern/vfs_subr.c
+++ b/sys/kern/vfs_subr.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: vfs_subr.c,v 1.245 2016/04/26 09:51:22 beck Exp $ */
+/* $OpenBSD: vfs_subr.c,v 1.246 2016/04/26 18:23:07 natano Exp $ */
/* $NetBSD: vfs_subr.c,v 1.53 1996/04/22 01:39:13 christos Exp $ */
/*
@@ -2276,6 +2276,6 @@ copy_statfs_info(struct statfs *sbp, const struct mount *mp)
memcpy(sbp->f_mntonname, mp->mnt_stat.f_mntonname, MNAMELEN);
memcpy(sbp->f_mntfromname, mp->mnt_stat.f_mntfromname, MNAMELEN);
memcpy(sbp->f_mntfromspec, mp->mnt_stat.f_mntfromspec, MNAMELEN);
- memcpy(&sbp->mount_info.ufs_args, &mp->mnt_stat.mount_info.ufs_args,
- sizeof(struct ufs_args));
+ memcpy(&sbp->mount_info, &mp->mnt_stat.mount_info,
+ sizeof(union mount_info));
}