Skip to content

Commit

Permalink
fix coverity bug
Browse files Browse the repository at this point in the history
  • Loading branch information
nobodyiam committed Apr 20, 2017
1 parent 36771bb commit 3996e64
Showing 1 changed file with 1 addition and 6 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -98,12 +98,7 @@ private void load() {

try {
Enumeration<NetworkInterface> interfaces = NetworkInterface.getNetworkInterfaces();
List<NetworkInterface> nis;
if (interfaces == null) {
nis = Collections.emptyList();
} else {
nis = Collections.list(NetworkInterface.getNetworkInterfaces());
}
List<NetworkInterface> nis = interfaces == null ? Collections.<NetworkInterface>emptyList() : Collections.list(interfaces);
List<InetAddress> addresses = new ArrayList<InetAddress>();
InetAddress local = null;

Expand Down

0 comments on commit 3996e64

Please sign in to comment.