Commit be5d629c authored by Max Kellermann's avatar Max Kellermann

Log: recognize class Error as nested exception

parent 957b399e
......@@ -98,6 +98,8 @@ LogError(const std::exception &e)
std::rethrow_if_nested(e);
} catch (const std::exception &nested) {
LogError(nested, "nested");
} catch (const Error &nested) {
LogError(nested, "nested");
} catch (...) {
Log(exception_domain, LogLevel::ERROR,
"Unrecognized nested exception");
......@@ -113,6 +115,8 @@ LogError(const std::exception &e, const char *msg)
std::rethrow_if_nested(e);
} catch (const std::exception &nested) {
LogError(nested);
} catch (const Error &nested) {
LogError(nested);
} catch (...) {
Log(exception_domain, LogLevel::ERROR,
"Unrecognized nested exception");
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment