mirror of
https://github.com/RGBCube/uutils-coreutils
synced 2025-07-28 19:47:45 +00:00
Merge pull request #7188 from ic3man5/main
sort: errors on overflowing -k argument but shouldn't
This commit is contained in:
commit
f731f2cba3
2 changed files with 23 additions and 3 deletions
|
@ -1302,3 +1302,14 @@ fn test_same_sort_mode_twice() {
|
|||
fn test_args_override() {
|
||||
new_ucmd!().args(&["-f", "-f"]).pipe_in("foo").succeeds();
|
||||
}
|
||||
|
||||
#[test]
|
||||
fn test_k_overflow() {
|
||||
let input = "2\n1\n";
|
||||
let output = "1\n2\n";
|
||||
new_ucmd!()
|
||||
.args(&["-k", "18446744073709551616"])
|
||||
.pipe_in(input)
|
||||
.succeeds()
|
||||
.stdout_is(output);
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue