fix for pairing primary and secondary alignments separately when writing
CRAM