From b072479bb85ef8d489b6d91847145d7865b85a4f Mon Sep 17 00:00:00 2001 From: Scott Sumner <30118311+sasumner@users.noreply.github.com> Date: Sat, 15 Aug 2020 19:45:43 -0400 Subject: [PATCH] Fix column key sort with col block starting in col1 bug Fix #8716, close #8717 --- PowerEditor/src/MISC/Common/Sorters.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/PowerEditor/src/MISC/Common/Sorters.h b/PowerEditor/src/MISC/Common/Sorters.h index 91f1192ab..cc4cff636 100644 --- a/PowerEditor/src/MISC/Common/Sorters.h +++ b/PowerEditor/src/MISC/Common/Sorters.h @@ -50,9 +50,9 @@ protected: { if (isSortingSpecificColumns()) { - // prevent an std::out_of_range exception if (input.length() < _fromColumn) { + // prevent an std::out_of_range exception return TEXT(""); } else if (_fromColumn == _toColumn) @@ -74,7 +74,7 @@ protected: bool isSortingSpecificColumns() { - return _fromColumn != 0 && _toColumn != 0; + return _toColumn != 0; } public: