Browse Source

SUNRPC: Fix another issue with rpc_client_register()

Fix the error pathway if rpcauth_create() fails.

Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
Trond Myklebust 12 years ago
parent
commit
1540c5d3cb
1 changed files with 1 additions and 0 deletions
  1. 1 0
      net/sunrpc/clnt.c

+ 1 - 0
net/sunrpc/clnt.c

@@ -309,6 +309,7 @@ static int rpc_client_register(const struct rpc_create_args *args,
 	return 0;
 err_auth:
 	pipefs_sb = rpc_get_sb_net(net);
+	rpc_unregister_client(clnt);
 	__rpc_clnt_remove_pipedir(clnt);
 out:
 	if (pipefs_sb)