[freenet-cvs] r12598 - trunk/freenet/src/freenet/node/fcp
nextgens at freenetproject.org
nextgens at freenetproject.org
Thu Apr 12 10:51:12 UTC 2007
Author: nextgens
Date: 2007-04-12 10:51:12 +0000 (Thu, 12 Apr 2007)
New Revision: 12598
Modified:
trunk/freenet/src/freenet/node/fcp/FCPConnectionHandler.java
Log:
Workaround the problem raised by Jflesch : test whether we can write before doing it...
Of course it sucks; the node has to have write access to figure out whether the client has.
Modified: trunk/freenet/src/freenet/node/fcp/FCPConnectionHandler.java
===================================================================
--- trunk/freenet/src/freenet/node/fcp/FCPConnectionHandler.java 2007-04-12 10:34:16 UTC (rev 12597)
+++ trunk/freenet/src/freenet/node/fcp/FCPConnectionHandler.java 2007-04-12 10:51:12 UTC (rev 12598)
@@ -356,7 +356,7 @@
inTestDirectories.put(directory, result);
}
- if(read){
+ if(read && (readFile != null) && readFile.canWrite()){
// We don't want to attempt to write before: in case an IOException is raised, we want to inform the
// client somehow that the node can't write there... And setting readFile to null means we won't inform
// it on the status (as if it hasn't requested us to do the test).
More information about the cvs
mailing list