From 34119798b0bb8e3960a7616d8ee2158fee0c15b4 Mon Sep 17 00:00:00 2001
From: lutoff <lutoff@localhost>
Date: Tue, 23 Sep 2008 13:12:05 +0000
Subject: [PATCH] fix for issue #3490 ( Uninstall produces a lot of erroneous warnings...)
---
opends/src/guitools/org/opends/guitools/uninstaller/Uninstaller.java | 23 ++++++++++++++++++++++-
1 files changed, 22 insertions(+), 1 deletions(-)
diff --git a/opends/src/guitools/org/opends/guitools/uninstaller/Uninstaller.java b/opends/src/guitools/org/opends/guitools/uninstaller/Uninstaller.java
index ef3b45d..d3a1df3 100644
--- a/opends/src/guitools/org/opends/guitools/uninstaller/Uninstaller.java
+++ b/opends/src/guitools/org/opends/guitools/uninstaller/Uninstaller.java
@@ -1112,18 +1112,39 @@
notifyListeners(getFormattedWithPoints(
INFO_PROGRESS_DELETING_INSTALLATION_FILES_NON_VERBOSE.get()));
}
+
String installPath = getInstallPathFromClasspath();
File installFile = new File(installPath);
+ try
+ {
+ installPath = installFile.getCanonicalPath();
+ }
+ catch(Exception e)
+ {
+ installPath = getInstallPathFromClasspath();
+ }
String instancePath =
Utils.getInstancePathFromClasspath(installFile.getAbsolutePath());
File instanceFile = new File(instancePath);
+ try
+ {
+ instancePath = instanceFile.getCanonicalPath();
+ } catch (Exception e)
+ {
+ instancePath =
+ Utils.getInstancePathFromClasspath(installFile.getAbsolutePath());
+ }
InstallationFilesToDeleteFilter filter =
new InstallationFilesToDeleteFilter();
File[] installFiles = installFile.listFiles();
- File[] instanceFiles = new File(instancePath).listFiles();
+ File[] instanceFiles = null ;
+ if (! installPath.equals(instancePath))
+ {
+ instanceFiles = new File(instancePath).listFiles();
+ }
File[] rootFiles = null;
--
Gitblit v1.10.0