From b6057c2f315a86d9327a682c17158d886d7174fb Mon Sep 17 00:00:00 2001
From: brutzman <brutzman@DESKTOP-2S09UKA>
Date: Tue, 6 Aug 2019 08:25:19 -0700
Subject: [PATCH] diagnostic comments

---
 examples/src/TcpExamples/TcpExample1Telnet.java | 3 +++
 1 file changed, 3 insertions(+)

diff --git a/examples/src/TcpExamples/TcpExample1Telnet.java b/examples/src/TcpExamples/TcpExample1Telnet.java
index 074e545611..5b976a622c 100644
--- a/examples/src/TcpExamples/TcpExample1Telnet.java
+++ b/examples/src/TcpExamples/TcpExample1Telnet.java
@@ -67,6 +67,9 @@ public class TcpExample1Telnet
             System.out.println("Problem with TcpExample1Telnet networking:"); // describe what is happening
             System.out.println("Error: " + e);
             // Provide more helpful information to user if exception occurs due to running twice at one time
+            
+            // brute force exception checking, can be brittle if exception message changes
+            // if (e.getMessage().equals("Address already in use: NET_Bind")) 
             if (e instanceof java.net.BindException)
                 System.out.println("*** Be sure to stop any other running instances of programs using this port!");
         }
-- 
GitLab