Fixed segfault if throw new exception in ErrorController