sort: fix -s -r interaction: 'stable' order is not affected by -r

function                                             old     new   delta
compare_keys                                         818     820      +2

Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
This commit is contained in:
Denys Vlasenko
2022-01-04 23:53:21 +01:00
parent dfd8aafcf5
commit cc7d2e2178
2 changed files with 16 additions and 1 deletions

View File

@@ -175,6 +175,19 @@ testing "sort file in place" \
111
" ""
testing "sort -sr (stable and reverse) does NOT reverse 'stable' ordering" \
"sort -k2 -r -s input" "\
b 2
d 2
a 1
c 1
" "\
a 1
b 2
c 1
d 2
" ""
# testing "description" "command(s)" "result" "infile" "stdin"
exit $FAILCOUNT