add explicit casts to XMALLOC()s, even for (void *), to avoid warnings in C++ and MSVC/MSVS builds, and to avoid false positives on simple text searches.

This commit is contained in:
Daniel Pouzzner
2020-12-02 13:32:48 -06:00
parent f47cdfcaed
commit f277339528
8 changed files with 10 additions and 10 deletions
+2 -2
View File
@@ -29045,7 +29045,7 @@ void *wolfSSL_ASN1_item_new(const WOLFSSL_ASN1_ITEM *tpl)
if (!tpl) {
return NULL;
}
if (!(ret = XMALLOC(tpl->size, NULL, DYNAMIC_TYPE_OPENSSL))) {
if (!(ret = (void *)XMALLOC(tpl->size, NULL, DYNAMIC_TYPE_OPENSSL))) {
return NULL;
}
XMEMSET(ret, 0, tpl->size);
@@ -31817,7 +31817,7 @@ void wolfSSL_OPENSSL_free(void* p)
void *wolfSSL_OPENSSL_malloc(size_t a)
{
return XMALLOC(a, NULL, DYNAMIC_TYPE_OPENSSL);
return (void *)XMALLOC(a, NULL, DYNAMIC_TYPE_OPENSSL);
}
int wolfSSL_OPENSSL_init_ssl(uint64_t opts, const OPENSSL_INIT_SETTINGS *settings)