hachikuji commented on a change in pull request #9985:
URL: https://github.com/apache/kafka/pull/9985#discussion_r566390451



##########
File path: raft/src/main/java/org/apache/kafka/raft/RaftConfig.java
##########
@@ -99,7 +99,7 @@
         public final InetSocketAddress address;
 
         public InetAddressSpec(InetSocketAddress address) {
-            if (address.equals(NON_ROUTABLE_ADDRESS)) {
+            if (address != null && address.equals(NON_ROUTABLE_ADDRESS)) {

Review comment:
       We also don't want to accept null addresses, right? I was thinking we 
could do this:
   ```java
   if (address == null || address.equals(NON_ROUTABLE_ADDRESS)) {
     throw new IllegalArgumentException("Invalid address " + address);
   }
   ```




----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


Reply via email to