fix bitrotted code in unexpected error tracing

This commit is contained in:
Andrew Kelley 2018-03-27 10:43:51 -04:00
parent c0a69a5075
commit 0b7b3190fd

View File

@ -1690,7 +1690,7 @@ const unexpected_error_tracing = false;
pub fn unexpectedErrorPosix(errno: usize) (error{Unexpected}) {
if (unexpected_error_tracing) {
debug.warn("unexpected errno: {}\n", errno);
debug.dumpStackTrace();
debug.dumpCurrentStackTrace(null);
}
return error.Unexpected;
}
@ -1700,7 +1700,7 @@ pub fn unexpectedErrorPosix(errno: usize) (error{Unexpected}) {
pub fn unexpectedErrorWindows(err: windows.DWORD) (error{Unexpected}) {
if (unexpected_error_tracing) {
debug.warn("unexpected GetLastError(): {}\n", err);
debug.dumpStackTrace();
debug.dumpCurrentStackTrace(null);
}
return error.Unexpected;
}