8048050: Agent NullPointerException when rmi.port in use
Reviewed-by: jbachorik, dfuchs
--- a/jdk/src/java.management/share/classes/sun/management/jmxremote/ConnectorBootstrap.java Tue Nov 18 16:20:16 2014 +0100
+++ b/jdk/src/java.management/share/classes/sun/management/jmxremote/ConnectorBootstrap.java Mon Nov 17 13:11:37 2014 +0100
@@ -767,7 +767,7 @@
JMXConnectorServerFactory.newJMXConnectorServer(url, env, mbs);
connServer.start();
} catch (IOException e) {
- if (connServer == null) {
+ if (connServer == null || connServer.getAddress() == null) {
throw new AgentConfigurationError(CONNECTOR_SERVER_IO_ERROR,
e, url.toString());
} else {