| 68 | #if defined(HAVE_STDLIB_H) |
| 69 | |
| 70 | void *srtp_crypto_alloc(size_t size) |
| 71 | { |
| 72 | void *ptr; |
| 73 | |
| 74 | if (!size) { |
| 75 | return NULL; |
| 76 | } |
| 77 | |
| 78 | ptr = calloc(1, size); |
| 79 | |
| 80 | if (ptr) { |
| 81 | debug_print(srtp_mod_alloc, "(location: %p) allocated", ptr); |
| 82 | } else { |
| 83 | debug_print(srtp_mod_alloc, "allocation failed (asked for %zu bytes)\n", |
| 84 | size); |
| 85 | } |
| 86 | |
| 87 | return ptr; |
| 88 | } |
| 89 | |
| 90 | void srtp_crypto_free(void *ptr) |
| 91 | { |
no outgoing calls