mirror of
https://github.com/eclipse-cdt/cdt
synced 2025-07-27 10:55:33 +02:00
[385416] NPE during shutdown with remote editor open
This commit is contained in:
parent
6345d1b3e7
commit
1c843c0bea
1 changed files with 9 additions and 6 deletions
|
@ -47,6 +47,7 @@
|
||||||
* Rick Sawyer (IBM) - [376535] RSE does not respect editor overrides
|
* Rick Sawyer (IBM) - [376535] RSE does not respect editor overrides
|
||||||
* David McKnight (IBM) - [357111] [DSTORE]File with invalid characters can't be opened in editor
|
* David McKnight (IBM) - [357111] [DSTORE]File with invalid characters can't be opened in editor
|
||||||
* David McKnight (IBM) - [385420] double-click to open System editor from Remote Systems view not working
|
* David McKnight (IBM) - [385420] double-click to open System editor from Remote Systems view not working
|
||||||
|
* David McKnight (IBM) - [385416] NPE during shutdown with remote editor open
|
||||||
*******************************************************************************/
|
*******************************************************************************/
|
||||||
|
|
||||||
package org.eclipse.rse.files.ui.resources;
|
package org.eclipse.rse.files.ui.resources;
|
||||||
|
@ -1866,11 +1867,13 @@ public class SystemEditableRemoteFile implements ISystemEditableRemoteObject, IP
|
||||||
//delete();
|
//delete();
|
||||||
|
|
||||||
SystemUniversalTempFileListener.getListener().unregisterEditedFile(this);
|
SystemUniversalTempFileListener.getListener().unregisterEditedFile(this);
|
||||||
|
IWorkbenchWindow win = SystemBasePlugin.getActiveWorkbenchWindow();
|
||||||
IWorkbenchPage page = SystemBasePlugin.getActiveWorkbenchWindow().getActivePage();
|
if (win != null){ // if the window is already closed, the listener doesn't matter
|
||||||
if (page != null){
|
IWorkbenchPage page = win.getActivePage();
|
||||||
page.removePartListener(this);
|
if (page != null){
|
||||||
editor = null;
|
page.removePartListener(this);
|
||||||
|
editor = null;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Add table
Reference in a new issue