On Fri, Mar 10, 2006 at 02:03:15PM +1300, Sam Vilain wrote:
> Why not just move the label?
>
> I think it is nicer if all of the exit points of a function are at the
> end, I've observed this to be a common convention and its success has
> actually made me jump off the 'goto=hell' bandwagon.
>
> gcc might even be optimising those duplicate instructions to a single
> one, so the duplication would be good documentation.
Sure, I thought of doing that as well, and I wasn't sure which was the
best option. I actually prefer not to have a label if its just going to
return. But I'm not religious about it. Here is an alternate patch that
does what you suggest.
NFS Client: Remove duplicate return in nfs_create_client()
Signed-Off-By: Horms <[email protected]>
inode.c | 2 --
1 file changed, 2 deletions(-)
65263bbdd17ed4ca75ac1c38165e5bd50eed146c
diff --git a/fs/nfs/inode.c b/fs/nfs/inode.c
index a77ee95..14aa539 100644
--- a/fs/nfs/inode.c
+++ b/fs/nfs/inode.c
@@ -414,8 +414,6 @@ nfs_create_client(struct nfs_server *ser
clnt->cl_intr = 1;
clnt->cl_softrtry = 1;
- return clnt;
-
out_fail:
return clnt;
}
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to [email protected]
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
[Index of Archives]
[Kernel Newbies]
[Netfilter]
[Bugtraq]
[Photo]
[Stuff]
[Gimp]
[Yosemite News]
[MIPS Linux]
[ARM Linux]
[Linux Security]
[Linux RAID]
[Video 4 Linux]
[Linux for the blind]
[Linux Resources]