Skip to content

Commit

Permalink
[hotfix][python] Fix possible null pointer exception in PythonDriver
Browse files Browse the repository at this point in the history
  • Loading branch information
dianfu committed Apr 13, 2021
1 parent 449048e commit 67b2cb3
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -132,7 +132,7 @@ public static void main(String[] args) throws Throwable {
}
} finally {
PythonEnvUtils.setGatewayServer(null);
if (Runtime.getRuntime().removeShutdownHook(shutdownHook)) {
if (shutdownHook != null && Runtime.getRuntime().removeShutdownHook(shutdownHook)) {
shutdownHook.run();
}
}
Expand Down

0 comments on commit 67b2cb3

Please sign in to comment.