diff options
author | 2015-05-17 12:43:50 -0400 | |
---|---|---|
committer | 2015-05-17 12:43:56 -0400 | |
commit | a545ee63bd4c620687e1f87fa5d76678114abe51 (patch) | |
tree | d51c9ba917529cd21f9178d3553de9457abc54a7 /src/lib/util/corealloc.c | |
parent | 48c49af416abceeacce3fa1e44b78ca5d9622c21 (diff) |
Change this error to a warning and don't drop into debugger for now (nw)
Diffstat (limited to 'src/lib/util/corealloc.c')
-rw-r--r-- | src/lib/util/corealloc.c | 13 |
1 files changed, 9 insertions, 4 deletions
diff --git a/src/lib/util/corealloc.c b/src/lib/util/corealloc.c index 1dd94081a38..0f752aa1b7c 100644 --- a/src/lib/util/corealloc.c +++ b/src/lib/util/corealloc.c @@ -17,6 +17,7 @@ //************************************************************************** #define LOG_ALLOCS (0) +#define DEBUG_MISMATCHED_ALLOCS (0) // define this to initialize allocated memory to a fixed non-0 value #ifdef MAME_DEBUG @@ -192,14 +193,18 @@ void free_file_line(void *memory, const char *file, int line, bool array) // warn about mismatched arrays if (!array && entry->m_array) { - fprintf(stderr, "Error: attempt to free array %p with global_free in %s(%d)!\n", memory, file, line); - osd_break_into_debugger("Error: attempt to free array with global_free"); + fprintf(stderr, "Warning: attempt to free array %p with global_free in %s(%d)!\n", memory, file, line); + if (DEBUG_MISMATCHED_ALLOCS) { + osd_break_into_debugger("Error: attempt to free array with global_free"); + } } if (array && !entry->m_array) { #ifndef __INTEL_COMPILER // todo: fix this properly, it appears some optimization the compiler applies breaks our logic here - fprintf(stderr, "Error: attempt to free single object %p with global_free_array in %s(%d)!\n", memory, file, line); - osd_break_into_debugger("Error: attempt to free single object with global_free_array"); + fprintf(stderr, "Warning: attempt to free single object %p with global_free_array in %s(%d)!\n", memory, file, line); + if (DEBUG_MISMATCHED_ALLOCS) { + osd_break_into_debugger("Error: attempt to free single object with global_free_array"); + } #endif } |