From a423bd00dbe9729881b4eb76bfbd47aebe5f3e6e Mon Sep 17 00:00:00 2001 From: Andrew D Smith Date: Sat, 16 May 2026 19:33:25 -0700 Subject: [PATCH] src/simreads.cpp: fixing bug in the mode that requires all reads to have valid alignments outside the N portion of the reference simulating from --- src/simreads.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/simreads.cpp b/src/simreads.cpp index 592e91e..2e67769 100644 --- a/src/simreads.cpp +++ b/src/simreads.cpp @@ -283,7 +283,7 @@ sim_frag_position(const std::string &genome, const std::size_t frag_len, // NOLINTBEGIN(*-narrowing-conversions) the_frag = std::string(g_beg + the_posn, g_beg + the_posn + frag_len); while (require_valid && - std::all_of(std::cbegin(the_frag), std::cend(the_frag), is_valid)) { + !std::all_of(std::cbegin(the_frag), std::cend(the_frag), is_valid)) { the_posn = simreads_random::rand() % lim; the_frag = std::string(g_beg + the_posn, g_beg + the_posn + frag_len); }