*/
#ifdef OPENSSL_FIPS
/* NB: in FIPS mode we are already under a lock */
- if (FIPS_mode())
+ if (!FIPS_mode())
#endif
CRYPTO_w_lock(CRYPTO_LOCK_RAND);
/* before unlocking, we must clear 'crypto_lock_rand' */
crypto_lock_rand = 0;
#ifdef OPENSSL_FIPS
- if (FIPS_mode())
+ if (!FIPS_mode())
#endif
CRYPTO_w_unlock(CRYPTO_LOCK_RAND);
MD_Update(&m,(unsigned char *)&(md_c[0]),sizeof(md_c));
MD_Update(&m,local_md,MD_DIGEST_LENGTH);
#ifdef OPENSSL_FIPS
- if (FIPS_mode())
+ if (!FIPS_mode())
#endif
CRYPTO_w_lock(CRYPTO_LOCK_RAND);
MD_Update(&m,md,MD_DIGEST_LENGTH);
MD_Final(&m,md);
#ifdef OPENSSL_FIPS
- if (FIPS_mode())
+ if (!FIPS_mode())
#endif
CRYPTO_w_unlock(CRYPTO_LOCK_RAND);