From ce5fbd6b6816547c5791d5adfacbf4deaed3ba21 Mon Sep 17 00:00:00 2001 From: elsid Date: Fri, 28 Apr 2023 13:28:52 +0200 Subject: [PATCH] Write separator between Detour status flags --- components/detournavigator/debug.cpp | 14 +++++++++++--- 1 file changed, 11 insertions(+), 3 deletions(-) diff --git a/components/detournavigator/debug.cpp b/components/detournavigator/debug.cpp index 8aa506fb3b..5a0d8779fd 100644 --- a/components/detournavigator/debug.cpp +++ b/components/detournavigator/debug.cpp @@ -114,9 +114,17 @@ namespace DetourNavigator std::ostream& operator<<(std::ostream& stream, const WriteDtStatus& value) { - for (const auto& status : dtStatuses) - if (value.mStatus & status.mStatus) - stream << status.mString; + bool first = true; + for (const auto& v : dtStatuses) + { + if ((value.mStatus & v.mStatus) == 0) + continue; + if (first) + first = false; + else + stream << " | "; + stream << v.mString; + } return stream; }