]> git.donarmstrong.com Git - samtools.git/commitdiff
* samtools-0.1.6-22 (r509)
authorHeng Li <lh3@live.co.uk>
Fri, 6 Nov 2009 14:17:09 +0000 (14:17 +0000)
committerHeng Li <lh3@live.co.uk>
Fri, 6 Nov 2009 14:17:09 +0000 (14:17 +0000)
 * forget to fix a similar problem in glfgen

bam_plcmd.c
bamtk.c

index e2601ecc3c26b41051d0148a9cf9696036d297fb..ba787a98bd78726503f48af1fd16582d89a357dd 100644 (file)
@@ -121,9 +121,11 @@ static int glt3_func(uint32_t tid, uint32_t pos, int n, const bam_pileup1_t *pu,
        g3->offset = pos - d->last_pos;
        d->last_pos = pos;
        glf3_write1(d->fp_glf, g3);
-       if (proposed_indels)
-               r = bam_maqindel(n, pos, d->ido, pu, d->ref, proposed_indels[0], proposed_indels+1);
-       else r = bam_maqindel(n, pos, d->ido, pu, d->ref, 0, 0);
+       if (pos < d->len) {
+               if (proposed_indels)
+                       r = bam_maqindel(n, pos, d->ido, pu, d->ref, proposed_indels[0], proposed_indels+1);
+               else r = bam_maqindel(n, pos, d->ido, pu, d->ref, 0, 0);
+       }
        if (r) { // then write indel line
                int het = 3 * n, min;
                min = het;
diff --git a/bamtk.c b/bamtk.c
index b4af0eca2037882ab1051eac41bbb502e8394225..890db11fda596a2f040e33ac89cbd2a4092ee738 100644 (file)
--- a/bamtk.c
+++ b/bamtk.c
@@ -9,7 +9,7 @@
 #endif
 
 #ifndef PACKAGE_VERSION
-#define PACKAGE_VERSION "0.1.6-21 (r508)"
+#define PACKAGE_VERSION "0.1.6-22 (r509)"
 #endif
 
 int bam_taf2baf(int argc, char *argv[]);