aboutsummaryrefslogtreecommitdiffstats
path: root/net
diff options
context:
space:
mode:
authorJ. Bruce Fields <bfields@citi.umich.edu>2010-03-17 13:02:48 -0400
committerTrond Myklebust <Trond.Myklebust@netapp.com>2010-05-14 15:09:15 -0400
commit54ec3d462f3c2a3fe48a7bd592160bee31360087 (patch)
tree4ae0027a9d40daed5d63b973c2f2895ddae45766 /net
parent7561042fb7870be0b4ee57efddce68bda8968abf (diff)
gss_krb5: Don't expect blocksize to always be 8 when calculating padding
Signed-off-by: Steve Dickson <steved@redhat.com> Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
Diffstat (limited to 'net')
-rw-r--r--net/sunrpc/auth_gss/gss_krb5_wrap.c5
1 files changed, 1 insertions, 4 deletions
diff --git a/net/sunrpc/auth_gss/gss_krb5_wrap.c b/net/sunrpc/auth_gss/gss_krb5_wrap.c
index 496281fabb91..5d6c3b12ea70 100644
--- a/net/sunrpc/auth_gss/gss_krb5_wrap.c
+++ b/net/sunrpc/auth_gss/gss_krb5_wrap.c
@@ -12,10 +12,7 @@
12static inline int 12static inline int
13gss_krb5_padding(int blocksize, int length) 13gss_krb5_padding(int blocksize, int length)
14{ 14{
15 /* Most of the code is block-size independent but currently we 15 return blocksize - (length % blocksize);
16 * use only 8: */
17 BUG_ON(blocksize != 8);
18 return 8 - (length & 7);
19} 16}
20 17
21static inline void 18static inline void