From 2fc7bf162040bbe10c63226285170ac6efda4fc0 Mon Sep 17 00:00:00 2001 From: Kirill Likhodedov Date: Wed, 29 Dec 2010 19:39:52 +0300 Subject: [PATCH] Check for already disposed. --- .../src/com/intellij/openapi/vcs/changes/IgnoredFileBean.java | 1 + .../src/com/intellij/openapi/vcs/changes/ChangesViewManager.java | 1 + 2 files changed, 2 insertions(+) diff --git a/platform/vcs-api/src/com/intellij/openapi/vcs/changes/IgnoredFileBean.java b/platform/vcs-api/src/com/intellij/openapi/vcs/changes/IgnoredFileBean.java index 02169295b063..b59fa802abf5 100644 --- a/platform/vcs-api/src/com/intellij/openapi/vcs/changes/IgnoredFileBean.java +++ b/platform/vcs-api/src/com/intellij/openapi/vcs/changes/IgnoredFileBean.java @@ -131,6 +131,7 @@ public class IgnoredFileBean { @Nullable private VirtualFile doResolve() { + if (myProject == null || myProject.isDisposed()) { return null; } VirtualFile baseDir = myProject.getBaseDir(); String path = FileUtil.toSystemIndependentName(myPath); diff --git a/platform/vcs-impl/src/com/intellij/openapi/vcs/changes/ChangesViewManager.java b/platform/vcs-impl/src/com/intellij/openapi/vcs/changes/ChangesViewManager.java index f462a5744e5e..5a3c8d0749a9 100644 --- a/platform/vcs-impl/src/com/intellij/openapi/vcs/changes/ChangesViewManager.java +++ b/platform/vcs-impl/src/com/intellij/openapi/vcs/changes/ChangesViewManager.java @@ -210,6 +210,7 @@ public class ChangesViewManager implements ChangesViewI, JDOMExternalizable, Pro @Override public void scheduleRefresh() { if (ApplicationManager.getApplication().isHeadlessEnvironment()) return; + if (myProject == null || myProject.isDisposed()) { return; } int was = myRepaintAlarm.cancelAllRequests(); if (LOG.isDebugEnabled()) { LOG.debug("schedule refresh, was " + was);