From aa61e881dedc2a886d9f823e15f5a3e47c5e43c8 Mon Sep 17 00:00:00 2001 From: Anna Kozlova Date: Mon, 24 Feb 2014 19:27:29 +0100 Subject: [PATCH] EA-54181 - NPE: NullableStuffInspectionBase.checkNullableStuffForMethod --- .../codeInspection/nullable/NullableStuffInspectionBase.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/java/java-analysis-impl/src/com/intellij/codeInspection/nullable/NullableStuffInspectionBase.java b/java/java-analysis-impl/src/com/intellij/codeInspection/nullable/NullableStuffInspectionBase.java index 0edaee491523..38f8d46fe10c 100644 --- a/java/java-analysis-impl/src/com/intellij/codeInspection/nullable/NullableStuffInspectionBase.java +++ b/java/java-analysis-impl/src/com/intellij/codeInspection/nullable/NullableStuffInspectionBase.java @@ -395,7 +395,7 @@ public class NullableStuffInspectionBase extends BaseJavaBatchLocalInspectionToo parameters[i].getNameIdentifier(); //be sure that corresponding tree element available PsiAnnotation annotation = AnnotationUtil.findAnnotation(parameters[i], nullableManager.getNotNulls()); PsiElement psiElement = annotation; - if (!annotation.isPhysical()) { + if (annotation == null || !annotation.isPhysical()) { psiElement = parameters[i].getNameIdentifier(); if (psiElement == null) continue; }