git: fa399b889f70 - stable/14 - ls: Fix -v and associated test
- Go to: [ bottom of page ] [ top of archives ] [ this month ]
Date: Wed, 28 Feb 2024 12:49:06 UTC
The branch stable/14 has been updated by gbe:
URL: https://cgit.FreeBSD.org/src/commit/?id=fa399b889f70dafb429e548919b0677a619677ef
commit fa399b889f70dafb429e548919b0677a619677ef
Author: Warner Losh <imp@FreeBSD.org>
AuthorDate: 2024-02-19 16:48:05 +0000
Commit: Gordon Bergling <gbe@FreeBSD.org>
CommitDate: 2024-02-28 12:47:33 +0000
ls: Fix -v and associated test
The cleanup of d854370fa86b7 had a cut and paste error (so f_verssort
was set to 1 and then to 0 rather thame f_timesort being set to 0).
Fixes: d854370fa86b7
Sponsored by: Netflix
(cherry picked from commit ef75877fc2d93199aab2b509089136c433af1f20)
---
bin/ls/ls.c | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/bin/ls/ls.c b/bin/ls/ls.c
index d358ece2d89e..59ff12547787 100644
--- a/bin/ls/ls.c
+++ b/bin/ls/ls.c
@@ -339,7 +339,7 @@ main(int argc, char *argv[])
case 'v':
f_verssort = 1;
f_sizesort = 0;
- f_verssort = 0;
+ f_timesort = 0;
break;
/* Other flags. Please keep alphabetic. */
case ',':
@@ -578,6 +578,7 @@ main(int argc, char *argv[])
blocksize /= 512;
}
}
+
/* Select a sort function. */
if (f_reversesort) {
if (f_sizesort)