We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 979bf72 commit 9b49869Copy full SHA for 9b49869
hivemq-edge/src/main/java/com/hivemq/HiveMQEdgeMain.java
@@ -174,10 +174,12 @@ public void start(final @Nullable EmbeddedExtension embeddedExtension)
174
175
public void stop() {
176
stopGateway();
177
- try {
178
- Runtime.getRuntime().removeShutdownHook(shutdownThread);
179
- } catch (final IllegalStateException ignored) {
180
- //ignore
+ if (shutdownThread != null) {
+ try {
+ Runtime.getRuntime().removeShutdownHook(shutdownThread);
+ } catch (final IllegalStateException ignored) {
181
+ //ignore
182
+ }
183
}
184
185
0 commit comments