1
0
mirror of https://github.com/OpenRCT2/OpenRCT2 synced 2026-01-18 20:43:04 +01:00

Convert NULL -> nullptr in C++

This commit is contained in:
Michał Janiszewski
2017-08-15 10:07:44 +02:00
committed by Michał Janiszewski
parent 44c8c84b7c
commit d698ad1100
94 changed files with 3189 additions and 3189 deletions

View File

@@ -353,7 +353,7 @@ bool NetworkKey::Sign(const uint8 * md, const size_t len, char ** signature, siz
*signature = nullptr;
/* Create the Message Digest Context */
if ((mdctx = EVP_MD_CTX_create()) == NULL)
if ((mdctx = EVP_MD_CTX_create()) == nullptr)
{
log_error("Failed to create MD context");
return false;
@@ -385,7 +385,7 @@ bool NetworkKey::Sign(const uint8 * md, const size_t len, char ** signature, siz
uint8 * sig;
/* Allocate memory for the signature based on size in slen */
if ((sig = (unsigned char*)malloc((sint32)(sizeof(unsigned char) * (*out_size)))) == NULL)
if ((sig = (unsigned char*)malloc((sint32)(sizeof(unsigned char) * (*out_size)))) == nullptr)
{
log_error("Failed to crypto-allocate space for signature");
EVP_MD_CTX_destroy(mdctx);
@@ -411,7 +411,7 @@ bool NetworkKey::Verify(const uint8 * md, const size_t len, const char * sig, co
EVP_MD_CTX * mdctx = nullptr;
/* Create the Message Digest Context */
if ((mdctx = EVP_MD_CTX_create()) == NULL)
if ((mdctx = EVP_MD_CTX_create()) == nullptr)
{
log_error("Failed to create MD context");
return false;