提交 ed9411a0 编写于 作者: C Chuck Lever 提交者: J. Bruce Fields

NFSD: Simplify GSS flavor encoding in nfsd4_do_encode_secinfo()

Clean up.
Signed-off-by: NChuck Lever <chuck.lever@oracle.com>
Signed-off-by: NJ. Bruce Fields <bfields@redhat.com>
上级 c8c797f9
...@@ -3119,17 +3119,11 @@ nfsd4_do_encode_secinfo(struct nfsd4_compoundres *resp, ...@@ -3119,17 +3119,11 @@ nfsd4_do_encode_secinfo(struct nfsd4_compoundres *resp,
struct rpcsec_gss_info info; struct rpcsec_gss_info info;
if (rpcauth_get_gssinfo(flavs[i].pseudoflavor, &info) == 0) { if (rpcauth_get_gssinfo(flavs[i].pseudoflavor, &info) == 0) {
RESERVE_SPACE(4); RESERVE_SPACE(4 + 4 + info.oid.len + 4 + 4);
WRITE32(RPC_AUTH_GSS); WRITE32(RPC_AUTH_GSS);
ADJUST_ARGS();
RESERVE_SPACE(4 + info.oid.len);
WRITE32(info.oid.len); WRITE32(info.oid.len);
WRITEMEM(info.oid.data, info.oid.len); WRITEMEM(info.oid.data, info.oid.len);
ADJUST_ARGS();
RESERVE_SPACE(4);
WRITE32(info.qop); WRITE32(info.qop);
ADJUST_ARGS();
RESERVE_SPACE(4);
WRITE32(info.service); WRITE32(info.service);
ADJUST_ARGS(); ADJUST_ARGS();
} else { } else {
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册