diff options
author | Lars Wirzenius <liw@liw.fi> | 2010-10-20 20:34:57 +0100 |
---|---|---|
committer | Lars Wirzenius <liw@liw.fi> | 2010-10-20 20:34:57 +0100 |
commit | bb7232044cfc09a51b899ab73d9df6d076d130fc (patch) | |
tree | be59d6c3ff62e0bc4038e292e555d23e5d59d260 | |
parent | 606314cb4919e3931036b09ed18f7fe936c26e42 (diff) | |
download | dynstr-bb7232044cfc09a51b899ab73d9df6d076d130fc.tar.gz |
Implement the default error handler for malloc.
-rw-r--r-- | dynstr.c | 5 |
1 files changed, 4 insertions, 1 deletions
@@ -15,9 +15,12 @@ struct Dynstr { }; +static dynstr_error_handler *error_handler = dynstr_malloc_error_indicate; + + dynstr_error_handler *dynstr_get_malloc_error_handler(void) { - return NULL; + return error_handler; } void dynstr_malloc_error_indicate(int error, size_t size, void *oldptr) |