diff options
| author | beck <> | 2014-04-17 13:37:50 +0000 |
|---|---|---|
| committer | beck <> | 2014-04-17 13:37:50 +0000 |
| commit | 6aa5f85bab6ba5f9189fbc3d53a12e0f6dae48dd (patch) | |
| tree | 7595a93a27385c367802aa17ecf20f96551cf14d /src/lib/libcrypto/asn1/a_bitstr.c | |
| parent | 4d13fb9c7b5ac7311d7031173c21ab0121388413 (diff) | |
| download | openbsd-6aa5f85bab6ba5f9189fbc3d53a12e0f6dae48dd.tar.gz openbsd-6aa5f85bab6ba5f9189fbc3d53a12e0f6dae48dd.tar.bz2 openbsd-6aa5f85bab6ba5f9189fbc3d53a12e0f6dae48dd.zip | |
Change library to use intrinsic memory allocation functions instead of
OPENSSL_foo wrappers. This changes:
OPENSSL_malloc->malloc
OPENSSL_free->free
OPENSSL_relloc->realloc
OPENSSL_freeFunc->free
Diffstat (limited to 'src/lib/libcrypto/asn1/a_bitstr.c')
| -rw-r--r-- | src/lib/libcrypto/asn1/a_bitstr.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/lib/libcrypto/asn1/a_bitstr.c b/src/lib/libcrypto/asn1/a_bitstr.c index 34179960b8..e2b65bf2ac 100644 --- a/src/lib/libcrypto/asn1/a_bitstr.c +++ b/src/lib/libcrypto/asn1/a_bitstr.c | |||
| @@ -144,7 +144,7 @@ ASN1_BIT_STRING *c2i_ASN1_BIT_STRING(ASN1_BIT_STRING **a, | |||
| 144 | 144 | ||
| 145 | if (len-- > 1) /* using one because of the bits left byte */ | 145 | if (len-- > 1) /* using one because of the bits left byte */ |
| 146 | { | 146 | { |
| 147 | s=(unsigned char *)OPENSSL_malloc((int)len); | 147 | s=(unsigned char *)malloc((int)len); |
| 148 | if (s == NULL) | 148 | if (s == NULL) |
| 149 | { | 149 | { |
| 150 | i=ERR_R_MALLOC_FAILURE; | 150 | i=ERR_R_MALLOC_FAILURE; |
| @@ -158,7 +158,7 @@ ASN1_BIT_STRING *c2i_ASN1_BIT_STRING(ASN1_BIT_STRING **a, | |||
| 158 | s=NULL; | 158 | s=NULL; |
| 159 | 159 | ||
| 160 | ret->length=(int)len; | 160 | ret->length=(int)len; |
| 161 | if (ret->data != NULL) OPENSSL_free(ret->data); | 161 | if (ret->data != NULL) free(ret->data); |
| 162 | ret->data=s; | 162 | ret->data=s; |
| 163 | ret->type=V_ASN1_BIT_STRING; | 163 | ret->type=V_ASN1_BIT_STRING; |
| 164 | if (a != NULL) (*a)=ret; | 164 | if (a != NULL) (*a)=ret; |
| @@ -192,7 +192,7 @@ int ASN1_BIT_STRING_set_bit(ASN1_BIT_STRING *a, int n, int value) | |||
| 192 | { | 192 | { |
| 193 | if (!value) return(1); /* Don't need to set */ | 193 | if (!value) return(1); /* Don't need to set */ |
| 194 | if (a->data == NULL) | 194 | if (a->data == NULL) |
| 195 | c=(unsigned char *)OPENSSL_malloc(w+1); | 195 | c=(unsigned char *)malloc(w+1); |
| 196 | else | 196 | else |
| 197 | c=(unsigned char *)OPENSSL_realloc_clean(a->data, | 197 | c=(unsigned char *)OPENSSL_realloc_clean(a->data, |
| 198 | a->length, | 198 | a->length, |
