aboutsummaryrefslogtreecommitdiffstats
path: root/crypto/openssl/crypto
diff options
context:
space:
mode:
authorJacques Vidrine <nectar@FreeBSD.org>2002-08-10 01:40:00 +0000
committerJacques Vidrine <nectar@FreeBSD.org>2002-08-10 01:40:00 +0000
commit9e6c5d1742cb27b1af95f09cda6cf8b330590e03 (patch)
treef0fcf1d2bc9428ac2d27136f2ac0d4a06cf28b96 /crypto/openssl/crypto
parentb1357e1cec95464ca388f5ea85e0b24cfac69efc (diff)
downloadsrc-9e6c5d1742cb27b1af95f09cda6cf8b330590e03.tar.gz
src-9e6c5d1742cb27b1af95f09cda6cf8b330590e03.zip
Import of OpenSSL 0.9.6f.
Notes
Notes: svn path=/vendor-crypto/openssl/dist/; revision=101613
Diffstat (limited to 'crypto/openssl/crypto')
-rw-r--r--crypto/openssl/crypto/asn1/asn1_lib.c7
-rw-r--r--crypto/openssl/crypto/bio/b_print.c2
-rw-r--r--crypto/openssl/crypto/cryptlib.c8
-rw-r--r--crypto/openssl/crypto/cryptlib.h4
-rw-r--r--crypto/openssl/crypto/mem.c3
-rw-r--r--crypto/openssl/crypto/opensslv.h4
6 files changed, 10 insertions, 18 deletions
diff --git a/crypto/openssl/crypto/asn1/asn1_lib.c b/crypto/openssl/crypto/asn1/asn1_lib.c
index a3681c0e23c7..e4a56a926af7 100644
--- a/crypto/openssl/crypto/asn1/asn1_lib.c
+++ b/crypto/openssl/crypto/asn1/asn1_lib.c
@@ -57,6 +57,7 @@
*/
#include <stdio.h>
+#include <limits.h>
#include "cryptlib.h"
#include <openssl/asn1.h>
#include <openssl/asn1_mac.h>
@@ -141,7 +142,7 @@ err:
static int asn1_get_length(unsigned char **pp, int *inf, long *rl, int max)
{
unsigned char *p= *pp;
- long ret=0;
+ unsigned long ret=0;
int i;
if (max-- < 1) return(0);
@@ -170,10 +171,10 @@ static int asn1_get_length(unsigned char **pp, int *inf, long *rl, int max)
else
ret=i;
}
- if (ret < 0)
+ if (ret > LONG_MAX)
return 0;
*pp=p;
- *rl=ret;
+ *rl=(long)ret;
return(1);
}
diff --git a/crypto/openssl/crypto/bio/b_print.c b/crypto/openssl/crypto/bio/b_print.c
index 90011db54496..fa4e350a7f93 100644
--- a/crypto/openssl/crypto/bio/b_print.c
+++ b/crypto/openssl/crypto/bio/b_print.c
@@ -109,7 +109,7 @@
* o ... (for OpenSSL)
*/
-#if HAVE_LONG_DOUBLE
+#ifdef HAVE_LONG_DOUBLE
#define LDOUBLE long double
#else
#define LDOUBLE double
diff --git a/crypto/openssl/crypto/cryptlib.c b/crypto/openssl/crypto/cryptlib.c
index 832c6c012d83..8fd2d4d26b82 100644
--- a/crypto/openssl/crypto/cryptlib.c
+++ b/crypto/openssl/crypto/cryptlib.c
@@ -491,11 +491,3 @@ BOOL WINAPI DLLEntryPoint(HINSTANCE hinstDLL, DWORD fdwReason,
#endif
#endif
-
-void OpenSSLDie(const char *file,int line,const char *assertion)
- {
- fprintf(stderr,"%s(%d): OpenSSL internal error, assertion failed: %s\n",
- file,line,assertion);
- abort();
- }
-
diff --git a/crypto/openssl/crypto/cryptlib.h b/crypto/openssl/crypto/cryptlib.h
index 576cbd6e3596..075b79db0580 100644
--- a/crypto/openssl/crypto/cryptlib.h
+++ b/crypto/openssl/crypto/cryptlib.h
@@ -93,10 +93,6 @@ extern "C" {
#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 die(e) ((e) ? (void)0 : OpenSSLDie(__FILE__, __LINE__, #e))
-
#ifdef __cplusplus
}
#endif
diff --git a/crypto/openssl/crypto/mem.c b/crypto/openssl/crypto/mem.c
index 3b5b2bbc6814..9df2a367e7e2 100644
--- a/crypto/openssl/crypto/mem.c
+++ b/crypto/openssl/crypto/mem.c
@@ -226,6 +226,9 @@ void *CRYPTO_realloc(void *str, int num, const char *file, int line)
{
void *ret = NULL;
+ if (str == NULL)
+ return CRYPTO_malloc(num, file, line);
+
if (realloc_debug_func != NULL)
realloc_debug_func(str, NULL, num, file, line, 0);
ret = realloc_func(str,num);
diff --git a/crypto/openssl/crypto/opensslv.h b/crypto/openssl/crypto/opensslv.h
index 7ee8f76dc90e..f1465ece09b9 100644
--- a/crypto/openssl/crypto/opensslv.h
+++ b/crypto/openssl/crypto/opensslv.h
@@ -25,8 +25,8 @@
* (Prior to 0.9.5a beta1, a different scheme was used: MMNNFFRBB for
* major minor fix final patch/beta)
*/
-#define OPENSSL_VERSION_NUMBER 0x0090605fL
-#define OPENSSL_VERSION_TEXT "OpenSSL 0.9.6e 30 Jul 2002"
+#define OPENSSL_VERSION_NUMBER 0x0090606fL
+#define OPENSSL_VERSION_TEXT "OpenSSL 0.9.6f 8 Aug 2002"
#define OPENSSL_VERSION_PTEXT " part of " OPENSSL_VERSION_TEXT