diff options
author | job <> | 2021-09-02 21:37:40 +0000 |
---|---|---|
committer | job <> | 2021-09-02 21:37:40 +0000 |
commit | 292968fb89e30fe8db20663ae2775ba85080f83f (patch) | |
tree | 73acce51def9de523ef40c28a364665d2bcafeae /src/lib | |
parent | 7467719dd38aa98062c41568540596fd9b8141d3 (diff) | |
download | openbsd-292968fb89e30fe8db20663ae2775ba85080f83f.tar.gz openbsd-292968fb89e30fe8db20663ae2775ba85080f83f.tar.bz2 openbsd-292968fb89e30fe8db20663ae2775ba85080f83f.zip |
Change OPENSSL_malloc to calloc()
OK tb@
Diffstat (limited to 'src/lib')
-rw-r--r-- | src/lib/libcrypto/x509/x509_asid.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/src/lib/libcrypto/x509/x509_asid.c b/src/lib/libcrypto/x509/x509_asid.c index 0c35efbfda..511002aab8 100644 --- a/src/lib/libcrypto/x509/x509_asid.c +++ b/src/lib/libcrypto/x509/x509_asid.c | |||
@@ -13,6 +13,7 @@ | |||
13 | 13 | ||
14 | #include <assert.h> | 14 | #include <assert.h> |
15 | #include <stdio.h> | 15 | #include <stdio.h> |
16 | #include <stdlib.h> | ||
16 | #include <string.h> | 17 | #include <string.h> |
17 | 18 | ||
18 | #include <openssl/asn1.h> | 19 | #include <openssl/asn1.h> |
@@ -619,7 +620,7 @@ static int ASIdentifierChoice_canonize(ASIdentifierChoice *choice) | |||
619 | ASRange *r; | 620 | ASRange *r; |
620 | switch (a->type) { | 621 | switch (a->type) { |
621 | case ASIdOrRange_id: | 622 | case ASIdOrRange_id: |
622 | if ((r = OPENSSL_malloc(sizeof(*r))) == NULL) { | 623 | if ((r = calloc(1, sizeof(*r))) == NULL) { |
623 | X509V3error(ERR_R_MALLOC_FAILURE); | 624 | X509V3error(ERR_R_MALLOC_FAILURE); |
624 | goto done; | 625 | goto done; |
625 | } | 626 | } |