Now checks if the i-th element of the FiltrationContext[] is null before trying to access it. This seems to happen occassionally at the very end of a VCF file... the array will be 6 elements long, but the last element will actually be null.

git-svn-id: file:///humgen/gsa-scr1/gsa-engineering/svn_contents/trunk@3097 348d0f76-0448-11de-a6fe-93d51630548a
This commit is contained in:
kiran 2010-03-30 22:40:17 +00:00
parent 400684542c
commit b9d3fc3fbb
1 changed files with 1 additions and 1 deletions

View File

@ -33,7 +33,7 @@ public class ClusteredSnps {
int currentIndex = i;
while ( ++currentIndex < variants.length ) {
if ( variants[currentIndex].getVariantContext().isVariant() ) {
if ( variants[currentIndex] != null && variants[currentIndex].getVariantContext() != null && variants[currentIndex].getVariantContext().isVariant() ) {
if ( ++snpsSeen == snpThreshold ) {
right = variants[currentIndex].getVariantContext().getLocation();
break;