Skip to main content
aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorEike Stepper2012-09-16 08:08:14 +0000
committerEike Stepper2012-09-16 08:08:14 +0000
commitf390e3073e7a7191163b5eb2e3678d017aa35ea3 (patch)
treee90681e842709329c4e08a5ba91a74b87850c637 /plugins
parentb1a4178ca7c5d3087e329f3b8fe6c41eb8f55d42 (diff)
downloadcdo-f390e3073e7a7191163b5eb2e3678d017aa35ea3.tar.gz
cdo-f390e3073e7a7191163b5eb2e3678d017aa35ea3.tar.xz
cdo-f390e3073e7a7191163b5eb2e3678d017aa35ea3.zip
Fix NPE in validateDelta()
Diffstat (limited to 'plugins')
-rw-r--r--plugins/org.eclipse.emf.cdo.releng.version.digest/src/org/eclipse/emf/cdo/releng/version/digest/DigestValidator.java17
1 files changed, 11 insertions, 6 deletions
diff --git a/plugins/org.eclipse.emf.cdo.releng.version.digest/src/org/eclipse/emf/cdo/releng/version/digest/DigestValidator.java b/plugins/org.eclipse.emf.cdo.releng.version.digest/src/org/eclipse/emf/cdo/releng/version/digest/DigestValidator.java
index 0149ea0888..456da91505 100644
--- a/plugins/org.eclipse.emf.cdo.releng.version.digest/src/org/eclipse/emf/cdo/releng/version/digest/DigestValidator.java
+++ b/plugins/org.eclipse.emf.cdo.releng.version.digest/src/org/eclipse/emf/cdo/releng/version/digest/DigestValidator.java
@@ -208,7 +208,9 @@ public class DigestValidator extends VersionValidator
for (IResourceDelta memberDelta : delta.getAffectedChildren())
{
IResource memberResource = memberDelta.getResource();
- DigestValidatorState memberState = validatorState.getChild(memberResource.getName());
+ DigestValidatorState memberState = validatorState != null ? validatorState.getChild(memberResource.getName())
+ : null;
+
DigestValidatorState newMemberState = validateDelta(memberDelta, memberState, componentModel, monitor);
if (newMemberState != null)
{
@@ -217,13 +219,16 @@ public class DigestValidator extends VersionValidator
}
}
- IContainer container = (IContainer)resource;
- for (DigestValidatorState oldChild : validatorState.getChildren())
+ if (validatorState != null)
{
- IResource member = container.findMember(oldChild.getName());
- if (member != null)
+ IContainer container = (IContainer)resource;
+ for (DigestValidatorState oldChild : validatorState.getChildren())
{
- memberStates.add(oldChild);
+ IResource member = container.findMember(oldChild.getName());
+ if (member != null)
+ {
+ memberStates.add(oldChild);
+ }
}
}

Back to the top