7a89988d6fd56140fd0b43c0f60430a210c24570
braney
  Thu May 19 16:41:30 2016 -0700
connecting things up for the long-range interaction display.

diff --git src/lib/bedTabix.c src/lib/bedTabix.c
index a10ced1..531dc57 100644
--- src/lib/bedTabix.c
+++ src/lib/bedTabix.c
@@ -5,35 +5,36 @@
 struct lineFile *lf = lineFileTabixMayOpen(fileOrUrl, TRUE);
 if (lf == NULL)
     return NULL;
 
 struct bedTabixFile *btf;
 AllocVar(btf);
 btf->lf = lf;
 if (isNotEmpty(chrom) && start != end)
     {
     lineFileSetTabixRegion(lf, chrom, start, end);
     }
 
 return btf;
 }
 
-struct bed *bedTabixReadBeds(struct bedTabixFile *btf, char *chrom, int start, int end, struct bed * (*loadBed)(void *tg), int minScore)
+struct bed *bedTabixReadBeds(struct bedTabixFile *btf, char *chrom, int start, int end, struct bed * (*loadBed)(void *tg))
 {
 struct bed *bedList = NULL;
 
 int wordCount;
 char *words[100];
 
-lineFileSetTabixRegion(btf->lf, chrom, start, end);
+if (!lineFileSetTabixRegion(btf->lf, chrom, start, end))
+    return NULL;
 while ((wordCount = lineFileChopTab(btf->lf, words)) > 0)
     {
     struct bed *bed = loadBed(words);
     slAddHead(&bedList, bed);
     }
 return bedList;
 }
 
 void bedTabixFileClose(struct bedTabixFile *btf)
 {
 lineFileClose(&btf->lf);
 }