summaryrefslogtreecommitdiff
path: root/core/net_crypto.c
diff options
context:
space:
mode:
Diffstat (limited to 'core/net_crypto.c')
-rw-r--r--core/net_crypto.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/core/net_crypto.c b/core/net_crypto.c
index 2dbe12ad..7fdd035f 100644
--- a/core/net_crypto.c
+++ b/core/net_crypto.c
@@ -408,7 +408,7 @@ int realloc_cryptoconnection(uint32_t num)
408{ 408{
409 Crypto_Connection *newcrypto_connections = realloc(crypto_connections, num * sizeof(Crypto_Connection)); 409 Crypto_Connection *newcrypto_connections = realloc(crypto_connections, num * sizeof(Crypto_Connection));
410 410
411 if (newcrypto_connections == NULL) 411 if (newcrypto_connections == NULL && num != 0)
412 return -1; 412 return -1;
413 413
414 crypto_connections = newcrypto_connections; 414 crypto_connections = newcrypto_connections;