Author: toad
Date: 2008-04-29 19:05:35 +0000 (Tue, 29 Apr 2008)
New Revision: 19619

Modified:
   trunk/freenet/src/freenet/node/IPDetectorPluginManager.java
Log:
Show alert as an error if there is evidence that ports aren't forwarded.

Modified: trunk/freenet/src/freenet/node/IPDetectorPluginManager.java
===================================================================
--- trunk/freenet/src/freenet/node/IPDetectorPluginManager.java 2008-04-29 
19:04:13 UTC (rev 19618)
+++ trunk/freenet/src/freenet/node/IPDetectorPluginManager.java 2008-04-29 
19:05:35 UTC (rev 19619)
@@ -81,7 +81,11 @@
                        if(connectionType == DetectedIP.SYMMETRIC_NAT || 
connectionType == DetectedIP.SYMMETRIC_UDP_FIREWALL)
                                // Only able to connect to directly connected / 
full cone nodes.
                                return UserAlert.ERROR;
-                       else return UserAlert.MINOR;
+                       if(portsNotForwarded != null) {
+                               for(int i=0;i<portsNotForwarded.length;i++)
+                                       if(portsNotForwarded[i] < 0) return 
UserAlert.ERROR;
+                       }
+                       return UserAlert.MINOR;
                }

                public String getShortText() {


Reply via email to