Skip to content

ls: fix zero block size handling to match GNU ls#8928

Merged
cakebaker merged 1 commit into
uutils:mainfrom
yrakcaz:main
Oct 17, 2025
Merged

ls: fix zero block size handling to match GNU ls#8928
cakebaker merged 1 commit into
uutils:mainfrom
yrakcaz:main

Conversation

@yrakcaz

@yrakcaz yrakcaz commented Oct 16, 2025

Copy link
Copy Markdown
Contributor

Fixes #8917

@codspeed-hq

codspeed-hq Bot commented Oct 16, 2025

Copy link
Copy Markdown

CodSpeed Performance Report

Merging #8928 will not alter performance

Comparing yrakcaz:main (3ff51d6) with main (db9c50c)

Summary

✅ 106 untouched
⏩ 73 skipped1

Footnotes

  1. 73 benchmarks were skipped, so the baseline results were used instead. If they were deleted from the codebase, click here and archive them to remove them from the performance reports.

@github-actions

Copy link
Copy Markdown

GNU testsuite comparison:

Skip an intermittent issue tests/misc/tee (fails in this run but passes in the 'main' branch)

Comment thread src/uu/ls/src/ls.rs Outdated
- Reject --block-size=0 with "invalid --block-size argument '0'" error
  using parse_size_non_zero_u64
- Add test coverage for both command-line and env var cases

Matches GNU ls behavior where command-line zero is invalid but
environment variable zero is silently ignored.
@github-actions

Copy link
Copy Markdown

GNU testsuite comparison:

Skipping an intermittent issue tests/misc/tee (passes in this run but fails in the 'main' branch)
Skipping an intermittent issue tests/rm/rm1 (passes in this run but fails in the 'main' branch)

@cakebaker cakebaker merged commit 85a7812 into uutils:main Oct 17, 2025
121 checks passed
@cakebaker

Copy link
Copy Markdown
Contributor

Thanks for your PR!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

ls: zero block size leads to "divide by zero" error

3 participants