Bug fix for Ryan: check for no context

This commit is contained in:
Eric Banks 2011-08-20 22:49:51 -04:00
parent 0ccd173967
commit a8cbced71b
2 changed files with 4 additions and 3 deletions

View File

@ -311,7 +311,8 @@ public class VariantEvalWalker extends RodWalker<Integer, Integer> implements Tr
// for each comp track
for ( final RodBinding<VariantContext> compRod : comps ) {
// no sample stratification for comps
final Set<VariantContext> compSet = compVCs.get(compRod) == null ? new HashSet<VariantContext>(0) : compVCs.get(compRod).values().iterator().next();
final HashMap<String, Set<VariantContext>> compSetHash = compVCs.get(compRod);
final Set<VariantContext> compSet = (compSetHash == null || compSetHash.size() == 0) ? new HashSet<VariantContext>(0) : compVCs.get(compRod).values().iterator().next();
// find the comp
final VariantContext comp = findMatchingComp(eval, compSet);

View File

@ -347,9 +347,9 @@ public class VariantEvalUtils {
}
}
}
bindings.put(track, mapping);
}
bindings.put(track, mapping);
}
return bindings;