More or less the subject explains the question. I'm building a web application with C++ and Wt. Of course I'm trying to be particularly careful with things that can cause a segfault, but it might happen. Wt creates a separate thread for every user opening a session. My worst fear is, specifically, that a malicious user finds a bug, which for example produces a segfault, and manages to exploit it, making the whole application crash at whim.
The preferred behaviour instead would be that I can "catch" the signal (yes, I know segfault isn't an exception, this is why I've used the quotes), kill the thread which produced it, maybe, if possible, freeing the memory it allocated and then keep the application running for the other users.
Is it possibile?
Thanks.