commons-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From ima...@apache.org
Subject svn commit: r331134 - /jakarta/commons/proper/vfs/trunk/src/java/org/apache/commons/vfs/provider/AbstractFileProvider.java
Date Sun, 06 Nov 2005 18:52:50 GMT
Author: imario
Date: Sun Nov  6 10:52:20 2005
New Revision: 331134

URL: http://svn.apache.org/viewcvs?rev=331134&view=rev
Log:
moved stuff out of synchronize() to avoid locks.
Thanks to Faron Dutton.

Modified:
    jakarta/commons/proper/vfs/trunk/src/java/org/apache/commons/vfs/provider/AbstractFileProvider.java

Modified: jakarta/commons/proper/vfs/trunk/src/java/org/apache/commons/vfs/provider/AbstractFileProvider.java
URL: http://svn.apache.org/viewcvs/jakarta/commons/proper/vfs/trunk/src/java/org/apache/commons/vfs/provider/AbstractFileProvider.java?rev=331134&r1=331133&r2=331134&view=diff
==============================================================================
--- jakarta/commons/proper/vfs/trunk/src/java/org/apache/commons/vfs/provider/AbstractFileProvider.java
(original)
+++ jakarta/commons/proper/vfs/trunk/src/java/org/apache/commons/vfs/provider/AbstractFileProvider.java
Sun Nov  6 10:52:20 2005
@@ -70,8 +70,9 @@
         synchronized (fileSystems)
         {
             fileSystems.clear();
-            super.close();
         }
+        
+        super.close();
     }
 
     /**
@@ -140,14 +141,15 @@
 
     public void closeFileSystem(final FileSystem filesystem)
     {
+        AbstractFileSystem fs = (AbstractFileSystem) filesystem;
+        
         synchronized (fileSystems)
         {
-            AbstractFileSystem fs = (AbstractFileSystem) filesystem;
-
             fileSystems.remove(fs.getCacheKey());
-            removeComponent(fileSystems);
-            fs.close();
         }
+        
+        removeComponent(fileSystems);
+        fs.close();
     }
 
     /**



---------------------------------------------------------------------
To unsubscribe, e-mail: commons-dev-unsubscribe@jakarta.apache.org
For additional commands, e-mail: commons-dev-help@jakarta.apache.org


Mime
View raw message