Fixed a bug where run-pipeline produces chunks of alignments that are
one alignment too long when using the in-memory representation as input.