Commit ee26e510 authored by Guido Casati's avatar Guido Casati

Use abort instead to exit in calloc_or_fail

* abort generates a core dump
parent 13757cfd
......@@ -75,7 +75,7 @@ static inline void *calloc_or_fail(size_t nmemb, size_t size)
if (ptr == NULL) {
fprintf(stderr, "Failed to calloc() %zu elements of %zu bytes: out of memory", nmemb, size);
exit(EXIT_FAILURE);
abort();
}
return 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