From 472fdfc43c5507f8c70101327e15e015c96ccdf6 Mon Sep 17 00:00:00 2001
From: tpylak <tpylak>
Date: Wed, 16 Sep 2009 20:44:34 +0000
Subject: [PATCH] SE-136 yeastx dataset upload bugfix: check if each dataset
 file is writable

SVN: 12651
---
 .../java/ch/systemsx/cisd/yeastx/etl/BatchDataSetHandler.java | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/rtd_yeastx/source/java/ch/systemsx/cisd/yeastx/etl/BatchDataSetHandler.java b/rtd_yeastx/source/java/ch/systemsx/cisd/yeastx/etl/BatchDataSetHandler.java
index cc40050b99d..800f5c04eee 100644
--- a/rtd_yeastx/source/java/ch/systemsx/cisd/yeastx/etl/BatchDataSetHandler.java
+++ b/rtd_yeastx/source/java/ch/systemsx/cisd/yeastx/etl/BatchDataSetHandler.java
@@ -196,7 +196,7 @@ public class BatchDataSetHandler implements IDataSetHandler
             log.error("File '%s' does not exist.", file.getPath());
             return false; // someone could deleted the file in the meantime
         }
-        if (isWritable(batchDir) == false)
+        if (isWritable(file) == false)
         {
             String path =
                     batchDir.getName() + System.getProperty("file.separator") + file.getName();
@@ -206,7 +206,7 @@ public class BatchDataSetHandler implements IDataSetHandler
                 log.adminError("Cannot acquire write access to '%s' "
                         + "because write access setter failed", path);
             }
-            return isWritable(batchDir);
+            return isWritable(file);
         } else
         {
             return true;
-- 
GitLab