mirror of
https://github.com/corda/corda.git
synced 2025-02-09 04:11:50 +00:00
Merge pull request #273 from jentfoo/master
Improved Throwable for if getCause is overridden
This commit is contained in:
commit
46f4e51c32
@ -12,7 +12,6 @@ package java.lang;
|
||||
|
||||
import java.io.PrintStream;
|
||||
import java.io.PrintWriter;
|
||||
import java.io.IOException;
|
||||
import java.io.Serializable;
|
||||
|
||||
public class Throwable implements Serializable {
|
||||
@ -113,9 +112,10 @@ public class Throwable implements Serializable {
|
||||
sb.append(" at ").append(trace[i].toString()).append(nl);
|
||||
}
|
||||
|
||||
if (cause != null) {
|
||||
Throwable printCause = getCause();
|
||||
if (printCause != null) {
|
||||
sb.append("caused by: ");
|
||||
cause.printStackTrace(sb, nl);
|
||||
printCause.printStackTrace(sb, nl);
|
||||
}
|
||||
}
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user