aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorSatyam Kandula2012-01-10 10:33:58 (EST)
committerMike Rennie2012-01-10 10:33:58 (EST)
commitb88619d3d013f09e240bb10a2d0e03291ed29015 (patch)
treebee347f277a6a7f8bf36d1ce873cd0c0334f5d3f
parente76447dfc4a7c5a669f1ad7bbffdecf25e69106a (diff)
downloadeclipse.platform-b88619d3d013f09e240bb10a2d0e03291ed29015.zip
eclipse.platform-b88619d3d013f09e240bb10a2d0e03291ed29015.tar.gz
eclipse.platform-b88619d3d013f09e240bb10a2d0e03291ed29015.tar.bz2
https://bugs.eclipse.org/312929
-rw-r--r--ant/org.eclipse.ant.launching/src/org/eclipse/ant/internal/launching/debug/model/AntDebugTarget.java3
-rw-r--r--ant/org.eclipse.ant.launching/src/org/eclipse/ant/internal/launching/debug/model/RemoteAntDebugBuildListener.java4
2 files changed, 3 insertions, 4 deletions
diff --git a/ant/org.eclipse.ant.launching/src/org/eclipse/ant/internal/launching/debug/model/AntDebugTarget.java b/ant/org.eclipse.ant.launching/src/org/eclipse/ant/internal/launching/debug/model/AntDebugTarget.java
index a320843..0d55ca8 100644
--- a/ant/org.eclipse.ant.launching/src/org/eclipse/ant/internal/launching/debug/model/AntDebugTarget.java
+++ b/ant/org.eclipse.ant.launching/src/org/eclipse/ant/internal/launching/debug/model/AntDebugTarget.java
@@ -337,13 +337,12 @@ public class AntDebugTarget extends AntDebugElement implements IDebugTarget, IDe
/**
* Called when this debug target terminates.
*/
- public void terminated() {
+ public synchronized void terminated() {
if(!fTerminated) {
fThreads= new IThread[0];
fTerminated = true;
fSuspended = false;
fController.terminate();
- fController = null;
if (DebugPlugin.getDefault() != null) {
DebugPlugin.getDefault().getBreakpointManager().removeBreakpointListener(this);
DebugPlugin.getDefault().removeDebugEventListener(this);
diff --git a/ant/org.eclipse.ant.launching/src/org/eclipse/ant/internal/launching/debug/model/RemoteAntDebugBuildListener.java b/ant/org.eclipse.ant.launching/src/org/eclipse/ant/internal/launching/debug/model/RemoteAntDebugBuildListener.java
index b13a14b..b29c513 100644
--- a/ant/org.eclipse.ant.launching/src/org/eclipse/ant/internal/launching/debug/model/RemoteAntDebugBuildListener.java
+++ b/ant/org.eclipse.ant.launching/src/org/eclipse/ant/internal/launching/debug/model/RemoteAntDebugBuildListener.java
@@ -177,10 +177,10 @@ public class RemoteAntDebugBuildListener extends RemoteAntBuildListener implemen
* @param request debug command
*/
protected void sendRequest(String request) {
- if (fRequestSocket == null) {
+ if (fRequestWriter == null) {
return;
}
- synchronized (fRequestSocket) {
+ synchronized (fRequestWriter) {
fRequestWriter.println(request);
}
}