fixed potential integer overflows

This commit is contained in:
Heng Li
2021-07-16 17:20:05 -04:00
parent b046052d82
commit 5f449c5cae
4 changed files with 4 additions and 4 deletions

View File

@@ -772,7 +772,7 @@ static void mm_align1(void *km, const mm_mapopt_t *opt, const mm_idx_t *mi, int
re1 = rs + (ez->max_t + 1);
qe1 = qs + (ez->max_q + 1);
if (cnt1 - (j + 1) >= opt->min_cnt) {
mm_split_reg(r, r2, as1 + j + 1 - r->as, qlen, a, opt->flag&MM_F_QSTRAND);
mm_split_reg(r, r2, as1 + j + 1 - r->as, qlen, a, !!(opt->flag&MM_F_QSTRAND));
if (zdrop_code == 2) r2->split_inv = 1;
}
break;