Skip to content

Commit

Permalink
fix bug with generating MD string on isovic#90
Browse files Browse the repository at this point in the history
  • Loading branch information
mdcao committed May 10, 2018
1 parent eb8c75d commit 14a6859
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion src/alignment/anchored.cc
Original file line number Diff line number Diff line change
Expand Up @@ -876,7 +876,9 @@ int AnchoredAlignmentNew(AlignmentFunctionType AlignmentFunctionNW, AlignmentFun
curr_aln->cigar = AlignmentToCigar((unsigned char *) &(curr_aln->alignment[0]), curr_aln->alignment.size(), parameters->use_extended_cigar);

LOG_DEBUG_SPEC("Converting alignment to MD string.\n");
curr_aln->md = AlignmentToMD((std::vector<unsigned char> &) curr_aln->alignment, &index->get_data()[0], final_aln_pos_start);
//curr_aln->md = AlignmentToMD((std::vector<unsigned char> &) curr_aln->alignment, &index->get_data()[0], final_aln_pos_start);
//MDC: fixed bug with generating MD
curr_aln->md = AlignmentToMD((std::vector<unsigned char> &) curr_aln->alignment, &index->get_data()[0] + index->get_reference_starting_pos()[ref_id], final_aln_pos_start);

// printf ("final_aln_pos_start = %ld\n", final_aln_pos_start);
// printf ("Query:\n%s\nTarget:\n%s\n", GetSubstring((char *) read->get_data(), read->get_data_length()).c_str(), GetSubstring((char *) index->get_data() + final_aln_pos_start, read->get_data_length()).c_str());
Expand Down

0 comments on commit 14a6859

Please sign in to comment.