Move to REF_DEBUG, for consistency.
[openssl.git] / crypto / asn1 / x_pkey.c
index 5bca68ad1e068b0665627aeb2c6ef24f3402bd3f..6e09d2923999c60db121b68ebc32f6cf3ff3977c 100644 (file)
@@ -90,17 +90,10 @@ void X509_PKEY_free(X509_PKEY *x)
         return;
 
     i = CRYPTO_add(&x->references, -1, CRYPTO_LOCK_X509_PKEY);
         return;
 
     i = CRYPTO_add(&x->references, -1, CRYPTO_LOCK_X509_PKEY);
-#ifdef REF_PRINT
-    REF_PRINT("X509_PKEY", x);
-#endif
+    REF_PRINT_COUNT("X509_PKEY", x);
     if (i > 0)
         return;
     if (i > 0)
         return;
-#ifdef REF_CHECK
-    if (i < 0) {
-        fprintf(stderr, "X509_PKEY_free, bad reference count\n");
-        abort();
-    }
-#endif
+    REF_ASSERT_ISNT(i < 0);
 
     X509_ALGOR_free(x->enc_algor);
     ASN1_OCTET_STRING_free(x->enc_pkey);
 
     X509_ALGOR_free(x->enc_algor);
     ASN1_OCTET_STRING_free(x->enc_pkey);