From ad74bf0a2cc09d0036a12793848b975e7b16eaa6 Mon Sep 17 00:00:00 2001
From: lutoff <lutoff@localhost>
Date: Fri, 27 Jul 2007 15:26:22 +0000
Subject: [PATCH]  modifications to fix issue #2022.

---
 opends/src/quicksetup/org/opends/quicksetup/util/FileManager.java |   12 +++++++-----
 1 files changed, 7 insertions(+), 5 deletions(-)

diff --git a/opends/src/quicksetup/org/opends/quicksetup/util/FileManager.java b/opends/src/quicksetup/org/opends/quicksetup/util/FileManager.java
index f3a9181..4a9dfba 100644
--- a/opends/src/quicksetup/org/opends/quicksetup/util/FileManager.java
+++ b/opends/src/quicksetup/org/opends/quicksetup/util/FileManager.java
@@ -158,7 +158,7 @@
         if (target.exists()) {
           if (!target.delete()) {
             throw new ApplicationException(
-                    ApplicationException.Type.FILE_SYSTEM_ERROR,
+                ApplicationReturnCode.ReturnCode.FILE_SYSTEM_ACCESS_ERROR,
                     getMsg("error-deleting-file",
                             Utils.getPath(target)), null);
           }
@@ -166,7 +166,7 @@
       }
       if (!fileToRename.renameTo(target)) {
         throw new ApplicationException(
-                ApplicationException.Type.FILE_SYSTEM_ERROR,
+            ApplicationReturnCode.ReturnCode.FILE_SYSTEM_ACCESS_ERROR,
                 getMsg("error-renaming-file",
                         Utils.getPath(fileToRename),
                         Utils.getPath(target)), null);
@@ -525,7 +525,7 @@
             } catch (Exception e) {
               String errMsg = getMsg("error-copying-file", args);
               throw new ApplicationException(
-                      ApplicationException.Type.FILE_SYSTEM_ERROR,
+                  ApplicationReturnCode.ReturnCode.FILE_SYSTEM_ACCESS_ERROR,
                       errMsg, null);
             } finally {
               if (fis != null) {
@@ -546,7 +546,8 @@
           } else {
             String errMsg = getMsg("error-copying-file", args);
             throw new ApplicationException(
-                    ApplicationException.Type.FILE_SYSTEM_ERROR, errMsg, null);
+                ApplicationReturnCode.ReturnCode.FILE_SYSTEM_ACCESS_ERROR,
+                errMsg, null);
           }
         } else {
           LOG.log(Level.INFO, "Ignoring file '" +
@@ -646,7 +647,8 @@
           errMsg = getMsg("error-deleting-directory", arg);
         }
         throw new ApplicationException(
-                ApplicationException.Type.FILE_SYSTEM_ERROR, errMsg, null);
+            ApplicationReturnCode.ReturnCode.FILE_SYSTEM_ACCESS_ERROR,
+            errMsg, null);
       }
 
       if (application != null) {

--
Gitblit v1.10.0