From c3898cc948028c9e125efd13c45b90ac0d105067 Mon Sep 17 00:00:00 2001
From: jvergara <jvergara@localhost>
Date: Wed, 05 Nov 2008 00:04:33 +0000
Subject: [PATCH] Fix for issue 3536 ( LDAP entry browser is broken in control panel when SSL or Start TLS are enabled on the server).
---
opends/src/guitools/org/opends/guitools/controlpanel/util/BackgroundTask.java | 12 ++++--------
1 files changed, 4 insertions(+), 8 deletions(-)
diff --git a/opends/src/guitools/org/opends/guitools/controlpanel/util/BackgroundTask.java b/opends/src/guitools/org/opends/guitools/controlpanel/util/BackgroundTask.java
index bb019f5..acb4a79 100644
--- a/opends/src/guitools/org/opends/guitools/controlpanel/util/BackgroundTask.java
+++ b/opends/src/guitools/org/opends/guitools/controlpanel/util/BackgroundTask.java
@@ -36,6 +36,7 @@
public abstract class BackgroundTask<T>
{
private BackgroundTaskThread<T> taskThread;
+ private boolean interrupted;
/**
* Creates a new thread and begins running the task in the background. When
* the task has completed, the {@code backgroundTaskCompleted} method will be
@@ -43,6 +44,7 @@
*/
public final void startBackgroundTask()
{
+ interrupted = false;
taskThread = new BackgroundTaskThread<T>(this);
taskThread.start();
}
@@ -53,6 +55,7 @@
*/
public final void interrupt()
{
+ interrupted = true;
if (taskThread != null)
{
taskThread.interrupt();
@@ -67,14 +70,7 @@
*/
public boolean isInterrupted()
{
- if (taskThread != null)
- {
- return taskThread.isInterrupted();
- }
- else
- {
- return false;
- }
+ return interrupted;
}
/**
--
Gitblit v1.10.0