Commit 253c396f authored by Gaston Dombiak's avatar Gaston Dombiak Committed by gato

Fixed null.[server] incorrect domain.

git-svn-id: http://svn.igniterealtime.org/svn/repos/wildfire/trunk@6781 b35dd754-fafc-0310-a699-88a17e54d16e
parent 48cfee9e
...@@ -92,7 +92,7 @@ public class STUNService extends BasicModule implements ServerItemsProvider, Rou ...@@ -92,7 +92,7 @@ public class STUNService extends BasicModule implements ServerItemsProvider, Rou
// Do nothing let the default values to be used. // Do nothing let the default values to be used.
} }
this.enabled = JiveGlobals.getProperty("stun.enabled") == null || Boolean.parseBoolean(JiveGlobals.getProperty("stun.enabled")); this.enabled = JiveGlobals.getBooleanProperty("stun.enabled", true);
} }
...@@ -105,6 +105,8 @@ public class STUNService extends BasicModule implements ServerItemsProvider, Rou ...@@ -105,6 +105,8 @@ public class STUNService extends BasicModule implements ServerItemsProvider, Rou
super.initialize(server); super.initialize(server);
routingTable = server.getRoutingTable(); routingTable = server.getRoutingTable();
router = server.getPacketRouter(); router = server.getPacketRouter();
serviceName = JiveGlobals.getProperty("stun.serviceName", name);
serviceName = serviceName == null ? name : serviceName.equals("") ? name : serviceName;
loadSTUNConfig(); loadSTUNConfig();
} }
...@@ -125,9 +127,6 @@ public class STUNService extends BasicModule implements ServerItemsProvider, Rou ...@@ -125,9 +127,6 @@ public class STUNService extends BasicModule implements ServerItemsProvider, Rou
if (primary != null && secondary != null) { if (primary != null && secondary != null) {
stunServer = new StunServer(primaryPort, primary, secondaryPort, secondary); stunServer = new StunServer(primaryPort, primary, secondaryPort, secondary);
serviceName = JiveGlobals.getProperty("stun.serviceName", name);
serviceName = serviceName == null ? name : serviceName.equals("") ? name : serviceName;
stunServer.start(); stunServer.start();
} else } else
...@@ -154,8 +153,7 @@ public class STUNService extends BasicModule implements ServerItemsProvider, Rou ...@@ -154,8 +153,7 @@ public class STUNService extends BasicModule implements ServerItemsProvider, Rou
if (stunServer != null) if (stunServer != null)
stunServer.stop(); stunServer.stop();
stunServer = null; stunServer = null;
XMPPServer.getInstance().getIQDiscoItemsHandler() XMPPServer.getInstance().getIQDiscoItemsHandler().removeComponentItem(getAddress().toString());
.removeComponentItem(getAddress().toString());
if (routingTable != null) if (routingTable != null)
routingTable.removeRoute(getAddress()); routingTable.removeRoute(getAddress());
} }
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment