mirror of https://github.com/apache/activemq.git
AMQ-4029: Check for null when unregister mbean.
git-svn-id: https://svn.apache.org/repos/asf/activemq/trunk@1383270 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
parent
8a0dd39fb0
commit
ece2e17b19
|
@ -174,7 +174,7 @@ public class ManagementContext implements Service {
|
|||
}
|
||||
// stop naming service mbean
|
||||
try {
|
||||
if (getMBeanServer().isRegistered(namingServiceObjectName)) {
|
||||
if (namingServiceObjectName != null && getMBeanServer().isRegistered(namingServiceObjectName)) {
|
||||
LOG.debug("Stopping MBean {}", namingServiceObjectName);
|
||||
getMBeanServer().invoke(namingServiceObjectName, "stop", null, null);
|
||||
LOG.debug("Unregistering MBean {}", namingServiceObjectName);
|
||||
|
|
Loading…
Reference in New Issue