8256808: com/sun/jdi/CatchAllTest.java failed with "NullPointerException: Cannot invoke "lib.jdb.Jdb.log(String)" because "this.jdb" is null"
Reviewed-by: cjplummer, sspitsyn
This commit is contained in:
parent
85269470e5
commit
c5b32b33eb
test/jdk/com/sun/jdi/lib/jdb
@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright (c) 2018, Oracle and/or its affiliates. All rights reserved.
|
||||
* Copyright (c) 2018, 2020, Oracle and/or its affiliates. All rights reserved.
|
||||
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
||||
*
|
||||
* This code is free software; you can redistribute it and/or modify it
|
||||
@ -260,7 +260,7 @@ public class Jdb implements AutoCloseable {
|
||||
command(JdbCommand.quit());
|
||||
}
|
||||
|
||||
void log(String s) {
|
||||
private void log(String s) {
|
||||
System.out.println(s);
|
||||
}
|
||||
|
||||
|
@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright (c) 2018, 2019, Oracle and/or its affiliates. All rights reserved.
|
||||
* Copyright (c) 2018, 2020, Oracle and/or its affiliates. All rights reserved.
|
||||
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
||||
*
|
||||
* This code is free software; you can redistribute it and/or modify it
|
||||
@ -94,9 +94,9 @@ public abstract class JdbTest {
|
||||
setup();
|
||||
runCases();
|
||||
} catch (Throwable e) {
|
||||
jdb.log("=======================================");
|
||||
jdb.log("Exception thrown during test execution: " + e.getMessage());
|
||||
jdb.log("=======================================");
|
||||
System.out.println("=======================================");
|
||||
System.out.println("Exception thrown during test execution: " + e.getMessage());
|
||||
System.out.println("=======================================");
|
||||
throw e;
|
||||
} finally {
|
||||
shutdown();
|
||||
|
Loading…
x
Reference in New Issue
Block a user