ErrorHandler Class[C++] class ErrorHandler : public RefCountable, public NoCopy
Members Overrides
Remarks FlowSshCpp handlers/overrides are invoked by internal FlowSshC worker threads. If an uncaught exception happens while triggering a handler or while executing one of your overrides, this exception triggers another handler, the [ErrorHandler]OnExceptionInHandler. With OnExceptionInHandler you get informed about uncaught exceptions that you would not notice otherwise. You should always register this handler through an Initializer before using any other FlowSshCpp functionality. Usually uncaught exceptions are simply logged so the flawed handler/override implementation can possibly be fixed later. For fatal errors one should also terminate the application, as memory leaks may occur due to undestroyed C++ objects created on the stack of the handler. Important: Never throw exceptions from this override, because they cannot be handled by the application. |