Removed unnecessary conditionals from logging statements.

Very important stuff.
This commit is contained in:
akwizgran
2014-03-12 21:00:14 +00:00
parent 375a597dd2
commit b99a503f24
33 changed files with 165 additions and 240 deletions

View File

@@ -113,8 +113,7 @@ class AliceConnector extends Connector {
tryToClose(conn, true);
return;
} catch(InterruptedException e) {
if(LOG.isLoggable(WARNING))
LOG.warning("Interrupted while waiting for confirmation");
LOG.warning("Interrupted while waiting for confirmation");
group.remoteConfirmationFailed();
tryToClose(conn, true);
Thread.currentThread().interrupt();

View File

@@ -113,8 +113,7 @@ class BobConnector extends Connector {
tryToClose(conn, true);
return;
} catch(InterruptedException e) {
if(LOG.isLoggable(WARNING))
LOG.warning("Interrupted while waiting for confirmation");
LOG.warning("Interrupted while waiting for confirmation");
group.remoteConfirmationFailed();
tryToClose(conn, true);
Thread.currentThread().interrupt();

View File

@@ -310,7 +310,7 @@ abstract class Connector extends Thread {
protected void tryToClose(DuplexTransportConnection conn,
boolean exception) {
try {
if(LOG.isLoggable(INFO)) LOG.info("Closing connection");
LOG.info("Closing connection");
conn.dispose(exception, true);
} catch(IOException e) {
if(LOG.isLoggable(WARNING)) LOG.log(WARNING, e.toString(), e);

View File

@@ -158,8 +158,7 @@ class ConnectorGroup extends Thread implements InvitationTask {
try {
for(Connector c : connectors) c.join();
} catch(InterruptedException e) {
if(LOG.isLoggable(WARNING))
LOG.warning("Interrupted while waiting for connectors");
LOG.warning("Interrupted while waiting for connectors");
}
// If none of the threads connected, inform the listeners
if(!connected.get()) {