EA-31156 - NPE: HTMLComposerImpl$1.visitFile
authorAnna Kozlova <anna.kozlova@jetbrains.com>
Wed, 1 Feb 2012 08:34:56 +0000 (12:34 +0400)
committerAnna Kozlova <anna.kozlova@jetbrains.com>
Wed, 1 Feb 2012 09:43:19 +0000 (13:43 +0400)
platform/lang-impl/src/com/intellij/codeInspection/ex/HTMLComposerImpl.java

index 08ad4e7b40c0b268f3675ac671e81f0b924a4805..71639a3a8339a3b3a44daec04f6c3caf843bdf84 100644 (file)
@@ -134,9 +134,11 @@ public abstract class HTMLComposerImpl extends HTMLComposer {
     refElement.accept(new RefVisitor() {
       @Override public void visitFile(RefFile file) {
         final PsiFile psiFile = file.getElement();
-        buf.append(B_OPENING);
-        buf.append(psiFile.getName());
-        buf.append(B_CLOSING);
+        if (psiFile != null) {
+          buf.append(B_OPENING);
+          buf.append(psiFile.getName());
+          buf.append(B_CLOSING);
+        }
       }
     });
   }