I thought it couldn't be caught, but I checked the docs, and it seems it can.
Hmm, maybe I should put that in all my programs - then I won't ever have bugs from segfaults.
:)
Hmm, maybe I should put that in all my programs - then I won't ever have bugs from segfaults.
:)
char foo[640*1024];
int main(int argc, char ** argv) { return 0; }
When ran, it made the OS say "Out of memory" and then it was lab assistant's headache to unload all that resident stuff that was sitting there and eating good 20-30% of available RAM. They typically opposed to doing that, so the TAs assumed the program actually worked. The end :)Hmm ... :)