File tree Expand file tree Collapse file tree 1 file changed +2
-1
lines changed
src/main/java/com/cloudbees/syslog/sender Expand file tree Collapse file tree 1 file changed +2
-1
lines changed Original file line number Diff line number Diff line change 3434import java .net .*;
3535import java .security .cert .Certificate ;
3636import java .security .cert .X509Certificate ;
37+ import java .util .Objects ;
3738import java .util .concurrent .atomic .AtomicInteger ;
3839import java .util .logging .Level ;
3940
@@ -118,7 +119,7 @@ public synchronized void sendMessage(@Nonnull SyslogMessage message) throws IOEx
118119
119120 private synchronized void ensureSyslogServerConnection () throws IOException {
120121 InetAddress inetAddress = syslogServerHostnameReference .get ();
121- if (socket != null && !socket .getInetAddress (). equals ( inetAddress )) {
122+ if (socket != null && !Objects . equals ( socket .getInetAddress (), inetAddress )) {
122123 logger .info ("InetAddress of the Syslog Server have changed, create a new connection. " +
123124 "Before=" + socket .getInetAddress () + ", new=" + inetAddress );
124125 IoUtils .closeQuietly (socket , writer );
You can’t perform that action at this time.
0 commit comments