summaryrefslogtreecommitdiffstats
path: root/crypto/cryptlib.h
diff options
context:
space:
mode:
authorBen Laurie <ben@openssl.org>2002-11-12 13:23:40 +0000
committerBen Laurie <ben@openssl.org>2002-11-12 13:23:40 +0000
commit9831d941ca3d46eab3e61e6983921220b9d5d09a (patch)
treeec628033e73b153616f300b3807921c9fe7de70f /crypto/cryptlib.h
parent707ceb29e04f7199f1ae619a6c0eab866fd15add (diff)
Many security improvements (CHATS) and a warning fix.
Diffstat (limited to 'crypto/cryptlib.h')
-rw-r--r--crypto/cryptlib.h10
1 files changed, 7 insertions, 3 deletions
diff --git a/crypto/cryptlib.h b/crypto/cryptlib.h
index 88e4ae509f..b8727aa6e1 100644
--- a/crypto/cryptlib.h
+++ b/crypto/cryptlib.h
@@ -89,9 +89,13 @@ extern "C" {
#define X509_CERT_DIR_EVP "SSL_CERT_DIR"
#define X509_CERT_FILE_EVP "SSL_CERT_FILE"
-/* size of string represenations */
-#define DECIMAL_SIZE(type) ((sizeof(type)*8+2)/3+1)
-#define HEX_SIZE(type) ((sizeof(type)*2)
+/* size of string representations */
+#define DECIMAL_SIZE(type) ((sizeof(type)*8+2)/3+1)
+#define HEX_SIZE(type) (sizeof(type)*2)
+
+/* die if we have to */
+void OpenSSLDie(const char *file,int line,const char *assertion);
+#define OPENSSL_assert(e) ((e) ? (void)0 : OpenSSLDie(__FILE__, __LINE__, #e))
#ifdef __cplusplus
}