From b5b50ac8da72bfe06810bbe24055dfb1218f83e3 Mon Sep 17 00:00:00 2001 From: Heng Li Date: Thu, 7 Mar 2013 21:35:57 -0500 Subject: [PATCH] r341: bugfix - wrong mate position when one end is mapped with a score less than -T. Caused by the -T option. --- bwamem_pair.c | 2 +- main.c | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/bwamem_pair.c b/bwamem_pair.c index 9ff12b3..49e9ad2 100644 --- a/bwamem_pair.c +++ b/bwamem_pair.c @@ -303,7 +303,7 @@ int mem_sam_pe(const mem_opt_t *opt, const bntseq_t *bns, const uint8_t *pac, co no_pairing: for (i = 0; i < 2; ++i) { - if (a[i].n) { + if (a[i].n && a[i].a[0].score >= opt->T) { mem_alnreg2hit(&a[i].a[0], &h[i]); bwa_fix_xref(opt->mat, opt->q, opt->r, opt->w, bns, pac, (uint8_t*)s[i].seq, &h[i].qb, &h[i].qe, &h[i].rb, &h[i].re); } else h[i].rb = h[i].re = -1; diff --git a/main.c b/main.c index da986a7..a772e3b 100644 --- a/main.c +++ b/main.c @@ -3,7 +3,7 @@ #include "utils.h" #ifndef PACKAGE_VERSION -#define PACKAGE_VERSION "0.7.0-r340-beta" +#define PACKAGE_VERSION "0.7.0-r341-beta" #endif int bwa_fa2pac(int argc, char *argv[]);