Move the big chunk of code at "terminal:" outside the loop; since it

has an unconditional loop break at the end this can be done safely,
now that the other loop break has been patched out.

Add a spurious set of braces to preserve the indent for the moment.
This commit is contained in:
dholland 2011-04-18 00:45:53 +00:00
parent 6a68e5d4c1
commit 58f787872f

View File

@ -1,4 +1,4 @@
/* $NetBSD: vfs_lookup.c,v 1.178 2011/04/18 00:45:29 dholland Exp $ */
/* $NetBSD: vfs_lookup.c,v 1.179 2011/04/18 00:45:53 dholland Exp $ */
/*
* Copyright (c) 1982, 1986, 1989, 1993
@ -37,7 +37,7 @@
*/
#include <sys/cdefs.h>
__KERNEL_RCSID(0, "$NetBSD: vfs_lookup.c,v 1.178 2011/04/18 00:45:29 dholland Exp $");
__KERNEL_RCSID(0, "$NetBSD: vfs_lookup.c,v 1.179 2011/04/18 00:45:53 dholland Exp $");
#include "opt_magiclinks.h"
@ -1261,7 +1261,11 @@ namei_oneroot(struct namei_state *state, struct vnode *forcecwd,
continue;
}
break;
}
terminal:
{
if (foundobj == ndp->ni_erootdir) {
/*
* We are about to return the emulation root.
@ -1348,9 +1352,8 @@ namei_oneroot(struct namei_state *state, struct vnode *forcecwd,
*/
VOP_UNLOCK(foundobj);
}
break;
}
alldone:
/*