diff options
author | Geoff Thorpe <geoff@openssl.org> | 2004-06-17 22:05:40 +0000 |
---|---|---|
committer | Geoff Thorpe <geoff@openssl.org> | 2004-06-17 22:05:40 +0000 |
commit | afbe74d386d2858e5e9c5839af56daa729172229 (patch) | |
tree | e723d57836d2e926ac3d74ee459847f0d06a2418 /crypto | |
parent | f18ea6cae92d0529de521b9c0a79f2846e1b4c29 (diff) |
Actually, that last change to BN_get_word() was a little too simple.
Diffstat (limited to 'crypto')
-rw-r--r-- | crypto/bn/bn_lib.c | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/crypto/bn/bn_lib.c b/crypto/bn/bn_lib.c index 8aa817dfc6..bbc359cb78 100644 --- a/crypto/bn/bn_lib.c +++ b/crypto/bn/bn_lib.c @@ -618,8 +618,10 @@ BN_ULONG BN_get_word(const BIGNUM *a) { if (a->top > 1) return BN_MASK2; - else + else if (a->top == 1) return a->d[0]; + /* a->top == 0 */ + return 0; } int BN_set_word(BIGNUM *a, BN_ULONG w) |