Author: toad
Date: 2009-01-22 23:56:59 +0000 (Thu, 22 Jan 2009)
New Revision: 25230

Modified:
   branches/db4o/freenet/src/freenet/io/comm/RetrievalException.java
   branches/db4o/freenet/src/freenet/node/RequestSender.java
Log:
Fix NPE


Modified: branches/db4o/freenet/src/freenet/io/comm/RetrievalException.java
===================================================================
--- branches/db4o/freenet/src/freenet/io/comm/RetrievalException.java   
2009-01-22 23:52:00 UTC (rev 25229)
+++ branches/db4o/freenet/src/freenet/io/comm/RetrievalException.java   
2009-01-22 23:56:59 UTC (rev 25230)
@@ -97,4 +97,8 @@
                                return "UNKNOWN ("+reason+")";
                }
        }
+       
+       public String getMessage() {
+               return toString();
+       }
 }

Modified: branches/db4o/freenet/src/freenet/node/RequestSender.java
===================================================================
--- branches/db4o/freenet/src/freenet/node/RequestSender.java   2009-01-22 
23:52:00 UTC (rev 25229)
+++ branches/db4o/freenet/src/freenet/node/RequestSender.java   2009-01-22 
23:56:59 UTC (rev 25230)
@@ -868,7 +868,7 @@
                                                        || reason == 
RetrievalException.UNABLE_TO_SEND_BLOCK_WITHIN_TIMEOUT);
                                                if(timeout) {
                                                        // Looks like a 
timeout. Backoff, even if it's a turtle.
-                                                       
next.transferFailed(e.getMessage());
+                                                       
next.transferFailed(e.toString());
                                                } else {
                                                        // Quick failure (in 
that we didn't have to timeout). Don't backoff.
                                                        // Treat as a DNF.

_______________________________________________
cvs mailing list
[email protected]
http://emu.freenetproject.org/cgi-bin/mailman/listinfo/cvs

Reply via email to