Search code examples
javawindowsswthandles

SWT - How to debug "No more handles"


from time to time I am haunted by the "org.eclipse.swt.SWTError: No more handles". I already know tools like GDIView, to watch the number of handles allocated, but now I wonder if there is a better way to do this.

Is there a tool available? Maybe one that logs all stacktraces when handles are created? And which shows the new handles between two invocation points?

Regards, Daniel

PS: Added the windows tag because dev occures mostly on windows and a windows only tool would be good enough.


Solution

  • I found out about Sleak, a great tool to debug SWT resources! Highly recommended for everyone with the same problems. Even shows the images for image resources!