But why do you want destructors to be called when you call exit()? You are exiting in an "abnormal" way anyway.
exit(0) is a normal termination, so destructors should be called. I wanna be nice and deallocate the allocated memory and unload dynamic libraries.
