linux 2.6.16.38 w/ vs2.0.3-rc1
[linux-2.6.git] / net / sunrpc / auth_gss / auth_gss.c
index 519ebc1..bb46efd 100644 (file)
@@ -721,8 +721,6 @@ gss_destroy(struct rpc_auth *auth)
 
        gss_auth = container_of(auth, struct gss_auth, rpc_auth);
        rpc_unlink(gss_auth->path);
-       dput(gss_auth->dentry);
-       gss_auth->dentry = NULL;
        gss_mech_put(gss_auth->mech);
 
        rpcauth_free_credcache(auth);
@@ -794,6 +792,7 @@ gss_create_cred(struct rpc_auth *auth, struct auth_cred *acred, int flags)
 
 out_err:
        dprintk("RPC:      gss_create_cred failed with error %d\n", err);
+       if (cred) gss_destroy_cred(&cred->gc_base);
        return ERR_PTR(err);
 }