mirror of
https://github.com/angryip/ipscan.git
synced 2025-10-26 11:18:17 +00:00
use closeQuietly
This commit is contained in:
parent
639b1c6b9d
commit
fc690f2b9c
@ -20,13 +20,14 @@ import org.eclipse.swt.widgets.MessageBox;
|
||||
|
||||
import javax.inject.Inject;
|
||||
import java.io.BufferedReader;
|
||||
import java.io.IOException;
|
||||
import java.io.InputStreamReader;
|
||||
import java.net.URL;
|
||||
import java.net.URLConnection;
|
||||
import java.util.logging.Level;
|
||||
import java.util.logging.Logger;
|
||||
|
||||
import static net.azib.ipscan.util.IOUtils.closeQuietly;
|
||||
|
||||
/**
|
||||
* HelpActions
|
||||
*
|
||||
@ -140,12 +141,8 @@ public class HelpMenuActions {
|
||||
Logger.getLogger(getClass().getName()).log(Level.WARNING, message, e);
|
||||
}
|
||||
finally {
|
||||
try {
|
||||
if (reader != null)
|
||||
reader.close();
|
||||
}
|
||||
catch (IOException e) {}
|
||||
|
||||
closeQuietly(reader);
|
||||
|
||||
// show the box in the SWT thread
|
||||
final String messageToShow = message;
|
||||
final int messageStyleToShow = messageStyle;
|
||||
|
||||
Loading…
Reference in New Issue
Block a user