From dde475e446050ba522ede0ec39f98f954367bc70 Mon Sep 17 00:00:00 2001 From: Pedro Martelletto Date: Sun, 11 Jul 2004 00:11:51 +0000 Subject: explicitly initialize a variable that is used to control the vnode flushing loop, otherwise we could hard-lock the machine when unmounting an union filesystem ok tedu@ --- sys/miscfs/union/union_vfsops.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'sys/miscfs/union') diff --git a/sys/miscfs/union/union_vfsops.c b/sys/miscfs/union/union_vfsops.c index 0fc8808fb3e..26c7aab8f70 100644 --- a/sys/miscfs/union/union_vfsops.c +++ b/sys/miscfs/union/union_vfsops.c @@ -1,4 +1,4 @@ -/* $OpenBSD: union_vfsops.c,v 1.20 2004/07/10 15:18:45 pedro Exp $ */ +/* $OpenBSD: union_vfsops.c,v 1.21 2004/07/11 00:11:50 pedro Exp $ */ /* $NetBSD: union_vfsops.c,v 1.10 1995/06/18 14:47:47 cgd Exp $ */ /* @@ -318,7 +318,7 @@ union_unmount(mp, mntflags, p) * in the filesystem. */ for (freeing = 0; vflush(mp, um_rootvp, flags) != 0;) { - int n; + int n = 0; /* count #vnodes held on mount list */ vfs_mount_foreach_vnode(mp, union_unmount_count_vnode, &n); -- cgit v1.2.3