From 0aa52784ef40ea92491ddd8785a2e2b97ade643f Mon Sep 17 00:00:00 2001
From: jvergara <jvergara@localhost>
Date: Thu, 15 Mar 2007 11:11:16 +0000
Subject: [PATCH] Fix for issue 1376.
---
opends/resource/uninstall.bat | 3 +--
opends/resource/uninstall | 3 ---
opends/src/quicksetup/org/opends/quicksetup/uninstaller/Uninstaller.java | 32 ++++----------------------------
3 files changed, 5 insertions(+), 33 deletions(-)
diff --git a/opends/resource/uninstall b/opends/resource/uninstall
index 014d0e8..898d14d 100644
--- a/opends/resource/uninstall
+++ b/opends/resource/uninstall
@@ -115,9 +115,6 @@
fi
fi
-# Configure the appropriate CLASSPATH to run uninstall.
-CLASSPATH=${INSTANCE_ROOT}/lib/quicksetup.jar:${INSTANCE_ROOT}/lib/OpenDS.jar
-export CLASSPATH
# Launch the uninstall process.
"${JAVA_BIN}" org.opends.quicksetup.uninstaller.UninstallLauncher "${@}"
diff --git a/opends/resource/uninstall.bat b/opends/resource/uninstall.bat
index a8e457f..219872f 100644
--- a/opends/resource/uninstall.bat
+++ b/opends/resource/uninstall.bat
@@ -52,8 +52,7 @@
goto end
:setClassPath
-call "%DIR_HOME%\bin\setcp.bat" %DIR_HOME%\lib\quicksetup.jar
-call "%DIR_HOME%\bin\setcp.bat" %DIR_HOME%\lib\OpenDS.jar
+FOR %%x in ("%DIR_HOME%\lib\*.jar") DO call "%DIR_HOME%\bin\setcp.bat" %%x
set PATH=%SystemRoot%
diff --git a/opends/src/quicksetup/org/opends/quicksetup/uninstaller/Uninstaller.java b/opends/src/quicksetup/org/opends/quicksetup/uninstaller/Uninstaller.java
index 4b8f2fa..10787f8 100644
--- a/opends/src/quicksetup/org/opends/quicksetup/uninstaller/Uninstaller.java
+++ b/opends/src/quicksetup/org/opends/quicksetup/uninstaller/Uninstaller.java
@@ -163,8 +163,7 @@
{
if (userData.getRemoveLibrariesAndTools())
{
- String[] arg = {getTab()+getQuicksetupJarPath()+
- getLineBreak()+getTab()+getOpenDSJarPath()};
+ String[] arg = {getLibrariesPath()};
successMsg = getMsg(
"summary-uninstall-finished-successfully-remove-jarfiles-cli",
arg);
@@ -178,8 +177,7 @@
{
if (userData.getRemoveLibrariesAndTools())
{
- String[] arg = {getTab()+getQuicksetupJarPath()+
- getLineBreak()+getTab()+getOpenDSJarPath()};
+ String[] arg = {getLibrariesPath()};
successMsg = getMsg(
"summary-uninstall-finished-successfully-remove-jarfiles", arg);
}
@@ -884,24 +882,6 @@
}
/**
- * Returns the path to the quicksetup jar file.
- * @return the path to the quicksetup jar file.
- */
- private String getQuicksetupJarPath()
- {
- return Utils.getPath(getLibrariesPath(), "quicksetup.jar");
- }
-
- /**
- * Returns the path to the open ds jar file.
- * @return the path to the open ds jar file.
- */
- private String getOpenDSJarPath()
- {
- return Utils.getPath(getLibrariesPath(), "OpenDS.jar");
- }
-
- /**
* Returns the path to the backup files under the install path.
* @return the path to the backup files under the install path.
*/
@@ -1162,8 +1142,6 @@
*/
class InstallationFilesToDeleteFilter implements FileFilter
{
- File quicksetupFile = new File(getQuicksetupJarPath());
- File openDSFile = new File(getOpenDSJarPath());
File librariesFile = new File(getLibrariesPath());
File installationPath = new File(Utils.getInstallPathFromClasspath());
@@ -1193,10 +1171,8 @@
};
boolean accept =
- !installationPath.equals(file)
- && !librariesFile.equals(file)
- && !quicksetupFile.equals(file)
- && !openDSFile.equals(file);
+ !installationPath.equals(file)&&
+ !equalsOrDescendant(file, librariesFile);
for (int i=0; i<uData.length && accept; i++)
{
--
Gitblit v1.10.0