Update error codes, move typedef of SSL, SSL_CTX to ossl_typ.h
[openssl.git] / crypto / bn / bn_lib.c
index 244a430d7229dd1be92401fa888ac477aa42db75..63cdc34c59b4467fc351f3253217cee2161b292c 100644 (file)
@@ -763,7 +763,7 @@ int BN_is_bit_set(const BIGNUM *a, int n)
        i=n/BN_BITS2;
        j=n%BN_BITS2;
        if (a->top <= i) return 0;
-       return((a->d[i]&(((BN_ULONG)1)<<j))?1:0);
+       return(((a->d[i])>>j)&((BN_ULONG)1));
        }
 
 int BN_mask_bits(BIGNUM *a, int n)