Commit 7193bd17 authored by J. Bruce Fields's avatar J. Bruce Fields

svcrpc: set cr_gss_mech from gss-proxy as well as legacy upcall

The change made to rsc_parse() in
0dc1531a "svcrpc: store gss mech in
svc_cred" should also have been propagated to the gss-proxy codepath.
This fixes a crash in the gss-proxy case.
Signed-off-by: default avatarJ. Bruce Fields <bfields@redhat.com>
parent 743e2171
...@@ -1180,6 +1180,7 @@ static int gss_proxy_save_rsc(struct cache_detail *cd, ...@@ -1180,6 +1180,7 @@ static int gss_proxy_save_rsc(struct cache_detail *cd,
gm = gss_mech_get_by_OID(&ud->mech_oid); gm = gss_mech_get_by_OID(&ud->mech_oid);
if (!gm) if (!gm)
goto out; goto out;
rsci.cred.cr_gss_mech = gm;
status = -EINVAL; status = -EINVAL;
/* mech-specific data: */ /* mech-specific data: */
...@@ -1195,7 +1196,6 @@ static int gss_proxy_save_rsc(struct cache_detail *cd, ...@@ -1195,7 +1196,6 @@ static int gss_proxy_save_rsc(struct cache_detail *cd,
rscp = rsc_update(cd, &rsci, rscp); rscp = rsc_update(cd, &rsci, rscp);
status = 0; status = 0;
out: out:
gss_mech_put(gm);
rsc_free(&rsci); rsc_free(&rsci);
if (rscp) if (rscp)
cache_put(&rscp->h, cd); cache_put(&rscp->h, cd);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment