Skip to main content
aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorPawel Piech2010-05-14 16:50:40 +0000
committerPawel Piech2010-05-14 16:50:40 +0000
commit06e479681f0a3dc7582cab9ef5cc420b353cfa8f (patch)
treea2a5eb44ebca663dc809570d5db26c72ec1734de /dsf/org.eclipse.cdt.dsf
parent1c2aa84166c0b1fff583f03b886fd7fb15688e13 (diff)
downloadorg.eclipse.cdt-06e479681f0a3dc7582cab9ef5cc420b353cfa8f.tar.gz
org.eclipse.cdt-06e479681f0a3dc7582cab9ef5cc420b353cfa8f.tar.xz
org.eclipse.cdt-06e479681f0a3dc7582cab9ef5cc420b353cfa8f.zip
Bug 312813 - [Launch] MIInferiorProcess.exitValue() never returns
Diffstat (limited to 'dsf/org.eclipse.cdt.dsf')
-rw-r--r--dsf/org.eclipse.cdt.dsf/src/org/eclipse/cdt/dsf/concurrent/Query.java5
1 files changed, 4 insertions, 1 deletions
diff --git a/dsf/org.eclipse.cdt.dsf/src/org/eclipse/cdt/dsf/concurrent/Query.java b/dsf/org.eclipse.cdt.dsf/src/org/eclipse/cdt/dsf/concurrent/Query.java
index 8416530707..69fceb597c 100644
--- a/dsf/org.eclipse.cdt.dsf/src/org/eclipse/cdt/dsf/concurrent/Query.java
+++ b/dsf/org.eclipse.cdt.dsf/src/org/eclipse/cdt/dsf/concurrent/Query.java
@@ -152,6 +152,7 @@ abstract public class Query<V> extends DsfRunnable
completed = fRm.isCompleted();
if (!completed) {
fRm.cancel();
+ fRm.notifyAll();
}
}
return !completed;
@@ -161,7 +162,8 @@ abstract public class Query<V> extends DsfRunnable
public boolean isDone() {
synchronized (fRm) {
- return fRm.isCompleted() || (fRm.isCanceled() && !fRm.isExecuted());
+ // If future is canceled, return right away.
+ return fRm.isCompleted() || fRm.isCanceled();
}
}
@@ -180,6 +182,7 @@ abstract public class Query<V> extends DsfRunnable
* @deprecated Query implementations should call the request monitor to
* set the exception status directly.
*/
+ @Deprecated
protected void doneException(Throwable t) {
fRm.setStatus(new Status(IStatus.ERROR, DsfPlugin.PLUGIN_ID, IDsfStatusConstants.INTERNAL_ERROR, "Exception", t)); //$NON-NLS-1$
fRm.done();

Back to the top