fix of NPE in IDEA-56157 Sort out performance problem with Perforce changelists refresh

This commit is contained in:
irengrig
2011-12-27 13:34:26 +04:00
parent 0f4ff0803b
commit f67b824d0b
@@ -76,7 +76,7 @@ public class VcsContentAnnotationImpl implements VcsContentAnnotation {
public boolean intervalRecentlyChanged(VirtualFile file, TextRange lineInterval, VcsRevisionNumber currentRevisionNumber) {
final ProjectLevelVcsManager vcsManager = ProjectLevelVcsManager.getInstance(myProject);
final AbstractVcs vcs = vcsManager.getVcsFor(file);
if (vcs == null) return false;
if (vcs == null || vcs.getDiffProvider() == null) return false;
if (currentRevisionNumber == null) {
currentRevisionNumber = vcs.getDiffProvider().getCurrentRevision(file);
assert currentRevisionNumber != null;