locking for windows (XP) partly debugged. ClientsFileTest watchers do not behave...
[vamsas.git] / src / org / vamsas / client / simpleclient / VamsasArchive.java
index c485124..c58c5f3 100644 (file)
@@ -533,7 +533,7 @@ public class VamsasArchive {
       rchive = new SessionFile(archive);
     if (!rchive.lockFile()) 
       throw new IOException("Failed to get lock on file "+archive);
-    newarchive = new JarOutputStream(new BufferedOutputStream(new java.io.FileOutputStream(archive)));  
+    newarchive = new JarOutputStream(rchive.fileLock.getBufferedOutputStream(true));  
     entries = new Hashtable();
   }
   public void putVamsasDocument(VamsasDocument doc) throws IOException,