I don't know how common it is, but at least Ubuntu has a standard environment variable called MALLOC_CHECK_ which typically is set to 2. When it is set, memory allocations are checked (it can also be set to 3). However, with DMD 1.040 this causes an "Aborted" message. Setting MALLOC_CHECK_ to 0 makes it work again.
I have tried to narrow down where it happens, but I seem to fail to get it much shorter than the following (and it seems that Exception itself from object.di may be involved):
class PlatformException : Exception
{
this(char[] msg)
{
super(msg);
}
}
class AssertException : Exception
{
this(char[] file, size_t line)
{
super("Assertion failure",file,line);
}
this(char[] msg, char[] file, size_t line)
{
super(msg,file,line);
}
}
void setAssertHandler(int){
}
This is a regression in DMD 1.040
Comment #1 by bugzilla — 2009-02-26T04:19:32Z
I didn't know about MALLOC_CHECK_. It's a great feature, and I found the (off by one) problem.