diff options
author | J. Bruce Fields <bfields@citi.umich.edu> | 2010-03-17 13:02:48 -0400 |
---|---|---|
committer | Trond Myklebust <Trond.Myklebust@netapp.com> | 2010-05-14 15:09:15 -0400 |
commit | 54ec3d462f3c2a3fe48a7bd592160bee31360087 (patch) | |
tree | 4ae0027a9d40daed5d63b973c2f2895ddae45766 /net | |
parent | 7561042fb7870be0b4ee57efddce68bda8968abf (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.c | 5 |
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 @@ | |||
12 | static inline int | 12 | static inline int |
13 | gss_krb5_padding(int blocksize, int length) | 13 | gss_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 | ||
21 | static inline void | 18 | static inline void |