Bug 436935 - Invalid thread access when exiting Eclipse after debugging

Change-Id: I7068ba3558e367c2fde35abbaaa89b9122c0f4b6
Signed-off-by: Marc-Andre Laperle <marc-andre.laperle@ericsson.com>
Reviewed-on: https://git.eclipse.org/r/28184
Tested-by: Hudson CI
Tested-by: Alvaro Sanchez-Leon <alvsan09@gmail.com>
Reviewed-by: Elena Laskavaia <elaskavaia.cdt@gmail.com>
Reviewed-by: Marc Khouzam <marc.khouzam@ericsson.com>
This commit is contained in:
Marc-Andre Laperle 2014-06-08 14:04:21 -04:00 committed by Elena Laskavaia
parent 60255bc58d
commit b87b828496

View file

@ -661,8 +661,8 @@ public class DsfSourceDisplayAdapter implements ISourceDisplay, ISteppingControl
// fSourceLookupParticipant is disposed by the source lookup director
// Need to remove annotations in UI thread.
Display display = Display.getDefault();
if (!display.isDisposed()) {
Display display = PlatformUI.getWorkbench().getDisplay();
if (display != null && !display.isDisposed()) {
display.asyncExec(new Runnable() {
@Override
public void run() {