From: kramm Date: Fri, 1 Apr 2005 07:59:03 +0000 (+0000) Subject: added some more info to the "out of memory" messages. X-Git-Tag: release-0-7-0~143 X-Git-Url: http://git.asbjorn.biz/?p=swftools.git;a=commitdiff_plain;h=da143dcc87b39085a4e6a4d51e145af7c11c815e added some more info to the "out of memory" messages. --- diff --git a/lib/rfxswf.c b/lib/rfxswf.c index 580a55d..616be52 100644 --- a/lib/rfxswf.c +++ b/lib/rfxswf.c @@ -61,8 +61,8 @@ void* rfx_alloc(int size) ptr = malloc(size); if(!ptr) { - fprintf(stderr, "FATAL: Out of memory\n"); - /* TODO: we should send a signal, so that the debugger kicks in */ + fprintf(stderr, "FATAL: Out of memory (while trying to claim %d bytes)\n", size); + /* TODO: we should send a signal, so that the debugger kicks in? */ exit(1); } return ptr; @@ -83,8 +83,8 @@ void* rfx_realloc(void*data, int size) } if(!ptr) { - fprintf(stderr, "FATAL: Out of memory\n"); - /* TODO: we should send a signal, so that the debugger kicks in */ + fprintf(stderr, "FATAL: Out of memory (while trying to claim %d bytes)\n", size); + /* TODO: we should send a signal, so that the debugger kicks in? */ exit(1); } return ptr; @@ -103,8 +103,8 @@ void* rfx_calloc(int size) ptr = malloc(size); #endif if(!ptr) { - fprintf(stderr, "FATAL: Out of memory\n"); - /* TODO: we should send a signal, so that the debugger kicks in */ + fprintf(stderr, "FATAL: Out of memory (while trying to claim %d bytes)\n", size); + /* TODO: we should send a signal, so that the debugger kicks in? */ exit(1); } #ifndef HAVE_CALLOC