From 8f096723829b176bdba12474550796fbce266a06 Mon Sep 17 00:00:00 2001 From: "Steffen (Daode) Nurpmeso" Date: Sat, 10 May 2014 01:08:36 +0200 Subject: [PATCH] salloc(): alert() if weird alloc request occurs --- strings.c | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/strings.c b/strings.c index f6386301..ab3e4b83 100644 --- a/strings.c +++ b/strings.c @@ -206,6 +206,10 @@ FL void * _all_wast += size - orig_size; size += _SHOPE_SIZE; + + if (size >= 2048) + alert("salloc() of %" ZFMT " bytes from `%s', line %u\n", + size, mdbg_file, mdbg_line); #endif /* Search for a buffer with enough free space to serve request */ -- 2.11.4.GIT