How to detect memory overrun in your 24/7 application, such as an online game server? The system and tool is linux + gcc.
Sometimes the cause of the memory overrun is writing the memory beyond the array; and sometimes the cause of the memory overrun is invalid pointers.
So, does anyone have some experience with this and know how to prevent it?
Prevention (at code level):
Detection (at run-time):