Skip to main content
aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
Diffstat (limited to 'codan/org.eclipse.cdt.codan.ui.cxx/src/org/eclipse/cdt/codan/ui/AbstractCodanCMarkerResolution.java')
-rw-r--r--codan/org.eclipse.cdt.codan.ui.cxx/src/org/eclipse/cdt/codan/ui/AbstractCodanCMarkerResolution.java5
1 files changed, 5 insertions, 0 deletions
diff --git a/codan/org.eclipse.cdt.codan.ui.cxx/src/org/eclipse/cdt/codan/ui/AbstractCodanCMarkerResolution.java b/codan/org.eclipse.cdt.codan.ui.cxx/src/org/eclipse/cdt/codan/ui/AbstractCodanCMarkerResolution.java
index 430cd68f7b9..50c8eca3911 100644
--- a/codan/org.eclipse.cdt.codan.ui.cxx/src/org/eclipse/cdt/codan/ui/AbstractCodanCMarkerResolution.java
+++ b/codan/org.eclipse.cdt.codan.ui.cxx/src/org/eclipse/cdt/codan/ui/AbstractCodanCMarkerResolution.java
@@ -275,6 +275,11 @@ public abstract class AbstractCodanCMarkerResolution implements ICodanMarkerReso
public IProblem getProblem(IMarker marker) {
IResource resource = marker.getResource();
+ if (resource == null) {
+ // IMarker.getResource() is not supposed to return null,
+ // but it looks like it sometimes does (bug 529383).
+ return null;
+ }
IProblemProfile profile = CodanRuntime.getInstance().getCheckersRegistry().getResourceProfile(resource);
String id = getProblemId(marker);
return profile.findProblem(id);

Back to the top