From c4321036be6de192e096175db12c12c9957348b2 Mon Sep 17 00:00:00 2001 From: Celine Mercier Date: Tue, 22 Jan 2019 15:17:59 +0100 Subject: [PATCH] Fixed length computation bug introduced in last version --- src/ecopcr.c | 13 +++++-------- 1 file changed, 5 insertions(+), 8 deletions(-) diff --git a/src/ecopcr.c b/src/ecopcr.c index 92e543d..2b236b6 100644 --- a/src/ecopcr.c +++ b/src/ecopcr.c @@ -6,7 +6,7 @@ #include -#define VERSION "1.0.0" +#define VERSION "1.0.1" /* ----------------------------------------------- */ @@ -610,13 +610,12 @@ int main(int argc, char **argv) { posj+=o2c->patlen; // printf("coucou %d %d %d\n",posi,posj,apatseq->seqlen); - errj =apatseq->hiterr[1]->val[j]; + errj = apatseq->hiterr[1]->val[j]; length = 0; if (posj > posi) length = posj - posi - o1->patlen - o2->patlen; if (posj < posi) - //length = posj + apatseq->seqlen - posi - o1->patlen - o2->patlen; // TODO - length = posi - posj - o1->patlen - o2->patlen; + length = posj + apatseq->seqlen - posi - o1->patlen - o2->patlen; if ((length>0) && // For when primers touch or overlap (!lmin || (length >= lmin)) && (!lmax || (length <= lmax))) @@ -668,11 +667,9 @@ int main(int argc, char **argv) length = 0; if (posj > posi) - //length = posj - posi + 1 - o2->patlen - o1->patlen; /* - o1->patlen : deleted by (prior to the OBITools3) */ TODO ???? - length = posj - posi - o2->patlen - o1->patlen; + length = posj - posi + 1 - o2->patlen - o1->patlen; /* - o1->patlen : deleted by (prior to the OBITools3) */ if (posj < posi) - //length = posj + apatseq->seqlen - posi - o1->patlen - o2->patlen; TODO ???? - length = posi - posj - o2->patlen - o1->patlen; + length = posj + apatseq->seqlen - posi - o1->patlen - o2->patlen; if ((length>0) && // For when primers touch or overlap (!lmin || (length >= lmin)) && (!lmax || (length <= lmax)))