Community
Participate
Working Groups
Hello, I ran into a critical endless loop (Unhandled event loop exception) causing a stack overflow when using swt. At first it looked like this: Instantiation of a Composite without setting a layout was immediately followed by the crash. Setting a layout afterwards solved it, but there is a deeper problem. I narrowed the problem down to a call of SWT.widgets.Control.computeSize(SWT.DEFAULT, SWT.DEFAULT), which might be calling user widgets to get into a loop. see bottom line of the log below. Best regards michael Eclipse for RCP and RAP Developers Version: Indigo Service Release 2 Build id: 20120216-1857 The Log: !SESSION 2013-06-11 13:26:39.235 ----------------------------------------------- eclipse.buildId=M20120208-0800 java.version=1.7.0_03 java.vendor=Oracle Corporation BootLoader constants: OS=linux, ARCH=x86_64, WS=gtk, NL=de_DE Framework arguments: -product org.eclipse.platform.ide Created Time: 2013-06-11 13:27:29.396 !ENTRY org.eclipse.ui 4 0 2013-06-11 13:27:29.396 !MESSAGE Unhandled event loop exception !STACK 0 org.eclipse.swt.SWTException: Failed to execute runnable (java.lang.StackOverflowError) at org.eclipse.swt.SWT.error(SWT.java:4282) at org.eclipse.swt.SWT.error(SWT.java:4197) at org.eclipse.swt.widgets.Synchronizer.runAsyncMessages(Synchronizer.java:138) at org.eclipse.swt.widgets.Display.runAsyncMessages(Display.java:3563) at org.eclipse.swt.widgets.Display.readAndDispatch(Display.java:3212) at org.eclipse.jface.window.Window.runEventLoop(Window.java:825) at org.eclipse.jface.window.Window.open(Window.java:801) at org.eclipse.jface.dialogs.MessageDialog.open(MessageDialog.java:334) at org.eclipse.ui.internal.ide.dialogs.InternalErrorDialog.open(InternalErrorDialog.java:80) at org.eclipse.ui.internal.ide.IDEWorkbenchErrorHandler.openQuestionDialog(IDEWorkbenchErrorHandler.java:199) at org.eclipse.ui.internal.ide.IDEWorkbenchErrorHandler.handleException(IDEWorkbenchErrorHandler.java:154) at org.eclipse.ui.internal.ide.IDEWorkbenchErrorHandler.access$0(IDEWorkbenchErrorHandler.java:146) at org.eclipse.ui.internal.ide.IDEWorkbenchErrorHandler$1.runInUIThread(IDEWorkbenchErrorHandler.java:121) at org.eclipse.ui.progress.UIJob$1.run(UIJob.java:95) at org.eclipse.swt.widgets.RunnableLock.run(RunnableLock.java:35) at org.eclipse.swt.widgets.Synchronizer.runAsyncMessages(Synchronizer.java:135) at org.eclipse.swt.widgets.Display.runAsyncMessages(Display.java:3563) at org.eclipse.swt.widgets.Display.readAndDispatch(Display.java:3212) at org.eclipse.ui.internal.Workbench.runEventLoop(Workbench.java:2701) at org.eclipse.ui.internal.Workbench.runUI(Workbench.java:2665) at org.eclipse.ui.internal.Workbench.access$4(Workbench.java:2499) at org.eclipse.ui.internal.Workbench$7.run(Workbench.java:679) at org.eclipse.core.databinding.observable.Realm.runWithDefault(Realm.java:332) at org.eclipse.ui.internal.Workbench.createAndRunWorkbench(Workbench.java:668) at org.eclipse.ui.PlatformUI.createAndRunWorkbench(PlatformUI.java:149) at org.eclipse.ui.internal.ide.application.IDEApplication.start(IDEApplication.java:123) at org.eclipse.equinox.internal.app.EclipseAppHandle.run(EclipseAppHandle.java:196) at org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher.runApplication(EclipseAppLauncher.java:110) at org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher.start(EclipseAppLauncher.java:79) at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:344) at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:179) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) at java.lang.reflect.Method.invoke(Method.java:601) at org.eclipse.equinox.launcher.Main.invokeFramework(Main.java:622) at org.eclipse.equinox.launcher.Main.basicRun(Main.java:577) at org.eclipse.equinox.launcher.Main.run(Main.java:1410) at org.eclipse.equinox.launcher.Main.main(Main.java:1386) Caused by: java.lang.StackOverflowError at org.eclipse.swt.widgets.Composite._getChildren(Composite.java:105) at org.eclipse.swt.widgets.Composite.minimumSize(Composite.java:1228) at org.eclipse.swt.widgets.Composite.computeSize(Composite.java:226) at org.eclipse.swt.widgets.Control.computeSize(Control.java:494) at mycustomXYComposite.getClientArea(mycustomXYComposite.java:204) at myOthereCustomXComposite.getClientArea(myOthereCustomXComposite.java:75) at org.eclipse.swt.widgets.Composite.minimumSize(Composite.java:1229) at org.eclipse.swt.widgets.Composite.computeSize(Composite.java:226) at org.eclipse.swt.widgets.Control.computeSize(Control.java:494) at mycustomXYComposite.getClientArea(mycustomXYComposite.java:204) at myOthereCustomXComposite.getClientArea(myOthereCustomXComposite.java:75) at org.eclipse.swt.widgets.Composite.minimumSize(Composite.java:1229) at org.eclipse.swt.widgets.Composite.computeSize(Composite.java:226) at org.eclipse.swt.widgets.Control.computeSize(Control.java:494) at mycustomXYComposite.getClientArea(mycustomXYComposite.java:204) at myOthereCustomXComposite.getClientArea(myOthereCustomXComposite.java:75) at org.eclipse.swt.widgets.Composite.minimumSize(Composite.java:1229) at org.eclipse.swt.widgets.Composite.computeSize(Composite.java:226) at org.eclipse.swt.widgets.Control.computeSize(Control.java:494) mycustomXYComposite.getClientArea(mycustomXYComposite.java:204) at myOthereCustomXComposite.getClientArea(myOthereCustomXComposite.java:75) at org.eclipse.swt.widgets.Composite.minimumSize(Composite.java:1229) at org.eclipse.swt.widgets.Composite.computeSize(Composite.java:226) at org.eclipse.swt.widgets.Control.computeSize(Control.java:494) looping
Moving to SWT.
Hi, can you provide a stand-alone snippet or plug-in that demonstrates the problem (ideal snippet template: http://www.eclipse.org/swt/faq.php#whatisasnippet )?
I'm closing this bug as there is not enough information to continue investigating it. Please re-open in case the problem is seen in the latest releases of Eclipse (4.3.2 or 4.4) and provide a set of steps or a snippet that can be used to reproduce the error.