diff --git a/bseq.c b/bseq.c index f68b11d..e499dda 100644 --- a/bseq.c +++ b/bseq.c @@ -53,7 +53,7 @@ bseq1_t *bseq_read(bseq_file_t *fp, int chunk_size, int with_qual, int *n_) size += seqs[n++].l_seq; if (size >= chunk_size) break; } - if (n == 0) fp->is_eof = 1; + if (size < chunk_size) fp->is_eof = 1; *n_ = n; return seqs; } diff --git a/index.c b/index.c index 6dc1f76..066a891 100644 --- a/index.c +++ b/index.c @@ -279,7 +279,7 @@ mm_idx_t *mm_idx_gen(bseq_file_t *fp, int w, int k, int b, int is_hpc, int mini_ { pipeline_t pl; memset(&pl, 0, sizeof(pipeline_t)); - pl.mini_batch_size = mini_batch_size; + pl.mini_batch_size = mini_batch_size < batch_size? mini_batch_size : batch_size; pl.keep_name = keep_name; pl.batch_size = batch_size; pl.fp = fp; diff --git a/main.c b/main.c index 3c312f1..dea1204 100644 --- a/main.c +++ b/main.c @@ -10,7 +10,7 @@ #include "minimap.h" #include "mmpriv.h" -#define MM_VERSION "2.0-r129-pre" +#define MM_VERSION "2.0-r131-pre" void liftrlimit() {