From: Heng Li Date: Thu, 2 Dec 2010 20:55:06 +0000 (+0000) Subject: a possible fix to DP4=0,0,0,0; have not tested, but should have no side-effect X-Git-Url: https://git.donarmstrong.com/?a=commitdiff_plain;h=e484b71874f60d3b37a62288bd5f4ed76487d38e;p=samtools.git a possible fix to DP4=0,0,0,0; have not tested, but should have no side-effect --- diff --git a/bcftools/call1.c b/bcftools/call1.c index 5e4fc9f..f293a6c 100644 --- a/bcftools/call1.c +++ b/bcftools/call1.c @@ -129,7 +129,7 @@ static int test16(bcf1_t *b, anno16_t *a) if ((p = strstr(b->info, "I16=")) == 0) return -1; p += 4; for (i = 0; i < 16; ++i) { - anno[i] = strtol(p, &p, 10); + errno = 0; anno[i] = strtol(p, &p, 10); if (anno[i] == 0 && (errno == EINVAL || errno == ERANGE)) return -2; ++p; }