smarco / WFA2-lib

WFA-lib: Wavefront alignment algorithm library v2

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Bug in overloaded WFAligner::alignEndsFree()

maxbbbb opened this issue · comments

commented

WFAligner::alignEndsFree() based on char* (line 106 in WFAligner.cpp) seems to be correct, but the other method based on std::string (line 122 in WFAligner.cpp) returns WFAligner::alignEnd2End(), which is not correct.

Instead, it is supposed to return WFAligner::alignEndsFree() using .c_str():

  return alignEndsFree(
      pattern.c_str(), pattern.length(), patternBeginFree, patternEndFree,
      text.c_str(), text.length(), textBeginFree, textEndFree);

Thanks for the report.

You are right! Solved in branch development (soon to be merged into main).