Unverified Commit e4f7f2a7 authored by Paul E. Jones's avatar Paul E. Jones Committed by GitHub

Merge pull request #391 from paulej/paulej_calloc_zero

Return NULL when allocating memory of size zero
parents 03e237e0 a6c434d7
......@@ -71,6 +71,10 @@ void *srtp_crypto_alloc(size_t size)
{
void *ptr;
if (!size) {
return NULL;
}
ptr = calloc(1, size);
if (ptr) {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment