Use Integer.parseInt(String) to get a primitive int.

This commit is contained in:
akwizgran
2013-04-25 05:07:26 +01:00
parent 178c486a4a
commit 1e5e78cc44
5 changed files with 5 additions and 5 deletions

View File

@@ -45,7 +45,7 @@ public class LanTcpPluginTest extends BriarTestCase {
assertEquals("127.0.0.1", host);
String portString = callback.local.get("port");
assertNotNull(portString);
int port = Integer.valueOf(portString);
int port = Integer.parseInt(portString);
assertTrue(port > 0 && port < 65536);
// The plugin should be listening on the port
InetSocketAddress addr = new InetSocketAddress(host, port);