Redefine the allocator functions to use the malloc family. * Only to be used when running module code from a non-Redis * context, such as unit tests. */
| 130 | * Only to be used when running module code from a non-Redis |
| 131 | * context, such as unit tests. */ |
| 132 | void Alloc_Reset() { |
| 133 | RedisModule_Alloc = malloc; |
| 134 | RedisModule_Realloc = realloc; |
| 135 | RedisModule_Calloc = calloc; |
| 136 | RedisModule_Free = free; |
| 137 | RedisModule_Strdup = strdup; |
| 138 | } |