| Summary: | Memory leak in WorkbenchPresentationFactory | ||||||
|---|---|---|---|---|---|---|---|
| Product: | [RT] RAP | Reporter: | Loïc Bertholet <loic.bertholet> | ||||
| Component: | Workbench | Assignee: | Project Inbox <rap-inbox> | ||||
| Status: | RESOLVED FIXED | QA Contact: | |||||
| Severity: | normal | ||||||
| Priority: | P3 | CC: | philippe.nembrard | ||||
| Version: | 1.2 | ||||||
| Target Milestone: | 1.3 M2 | ||||||
| Hardware: | All | ||||||
| OS: | All | ||||||
| Whiteboard: | |||||||
| Attachments: |
|
||||||
Created attachment 147296 [details]
Propersed fix
Fixed in CVS HEAD |
Steps to reproduce: * Open one and only one editor * Close the editor * 16 ko are not released As there is no more opened editor, EditorSashConainer.removeEditor(EditorPane pane) remove the EditorStack called "workbook" and create another one. This process includes calling WorkbenchPresentationFactory.createEditorPresentation(...) which add a SessionStoreListener in order to release some stuff when session will be invalidated. Objects contained in this listener retain almost 16 ko. The problem is that each time that the only opened editor is closed, 16 more ko are retained until session invalidation. I have a patch which replaces the session store listener by a dispose listener on the TabbedStackPresentation control with widgetDisposed(...) executing the same code as beforeDestroy(...) result.getControl().addDisposeListener(new DisposeListener() { public void widgetDisposed(DisposeEvent event) { defaultMultiTabListener.attach(null, IWorkbenchPreferenceConstants.SHOW_MULTIPLE_EDITOR_TABS, true); } });