From 5bd90e8071322ab52d02e6562e9762cce4e130e6 Mon Sep 17 00:00:00 2001 From: David McKnight Date: Thu, 30 Sep 2010 20:28:52 +0000 Subject: [PATCH] [326555] Dead lock when debug session starts --- .../org/eclipse/rse/core/subsystems/SubSystem.java | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/rse/plugins/org.eclipse.rse.ui/subsystems/org/eclipse/rse/core/subsystems/SubSystem.java b/rse/plugins/org.eclipse.rse.ui/subsystems/org/eclipse/rse/core/subsystems/SubSystem.java index 3182cebc570..ad352e35c00 100644 --- a/rse/plugins/org.eclipse.rse.ui/subsystems/org/eclipse/rse/core/subsystems/SubSystem.java +++ b/rse/plugins/org.eclipse.rse.ui/subsystems/org/eclipse/rse/core/subsystems/SubSystem.java @@ -1,5 +1,5 @@ /******************************************************************************** - * Copyright (c) 2002, 20010 IBM Corporation and others. All rights reserved. + * Copyright (c) 2002, 2010 IBM Corporation and others. All rights reserved. * This program and the accompanying materials are made available under the terms * of the Eclipse Public License v1.0 which accompanies this distribution, and is * available at http://www.eclipse.org/legal/epl-v10.html @@ -49,6 +49,7 @@ * David McKnight (IBM) - [272882] [api] Handle exceptions in IService.initService() * David McKnight (IBM) - [284018] concurrent SubSystem.connect() calls can result in double login-prompt * David McKnight (IBM) - [318836] Period in filter name causes wrong message on drag and drop + * David McKnight (IBM) - [326555] Dead lock when debug session starts * ********************************************************************************/ package org.eclipse.rse.core.subsystems; @@ -2478,7 +2479,8 @@ implements IAdaptable, ISubSystem, ISystemFilterPoolReferenceManagerProvider } public synchronized void waitUntilNotContained(IConnectorService cs) { - while (contains(cs)){ // wait until the connector service is no longer in the list + while (contains(cs) && // wait until the connector service is no longer in the list + Display.getCurrent() == null){ // for bug 326555, don't wait when on the main thread - otherwise there will be a hang try { wait(); }