RFR: 8256808: com/sun/jdi/CatchAllTest.java failed with "NullPointerException: Cannot invoke "lib.jdb.Jdb.log(String)" because "this.jdb" is null"

Chris Plummer cjplummer at openjdk.java.net
Mon Nov 30 23:32:57 UTC 2020


On Thu, 26 Nov 2020 18:04:18 GMT, Aleksey Shipilev <shade at openjdk.org> wrote:

> Why not just print it to `System.out` then, eliminating the method altogether?

There are a 2 of other references to log() within the Jdb class. I think the only real value log() has is in case you need to (temporarily) run a test with Jdb output directed somewhere else, or maybe you want to add a prefix to the output.

I'm ok with the fix as is, but also wouldn't object to removing log() and changing all references to System.out.println.

-------------

PR: https://git.openjdk.java.net/jdk/pull/1443


More information about the serviceability-dev mailing list