365267 NullPointerException in bad Address

This commit is contained in:
Jan Bartel 2011-12-02 10:04:03 +11:00
parent de005c68fd
commit 468e6c284d
1 changed files with 3 additions and 0 deletions

View File

@ -43,6 +43,9 @@ public class Address
public Address(String host, int port)
{
if (host == null)
throw new IllegalArgumentException("Host is null");
this.host = host.trim();
this.port = port;
}