Page MenuHomeFreeBSD

df: fix various compiler warnings and improve code quality
Needs ReviewPublic

Authored by aalx2176_gmail.com on Apr 27 2026, 6:27 PM.
Tags
None
Referenced Files
Unknown Object (File)
Tue, Sep 8, 1:12 AM
Unknown Object (File)
Sat, Sep 5, 10:31 AM
Unknown Object (File)
Fri, Sep 4, 11:17 PM
Unknown Object (File)
Fri, Sep 4, 10:26 PM
Unknown Object (File)
Sat, Aug 29, 11:00 AM
Unknown Object (File)
Wed, Aug 26, 9:33 AM
Unknown Object (File)
Thu, Aug 20, 1:18 PM
Unknown Object (File)
Wed, Aug 19, 11:56 AM
Subscribers

Details

Reviewers
None
Group Reviewers
Contributor Reviews (src)
Src Committers
Summary
  • Add __dead2 attribute to usage()
  • Use correct types (ssize_t and size_t) for mount point counts and buffer lengths to avoid 64-to-32 truncation
  • Fix invalid escape sequence in xo_emit format string
  • Remove redundant sizeof(char) in malloc()
Test Plan

Compiled with -Weverything -Wno-unsafe-buffer-usage -Wno-sign-conversion and verified output manually

Diff Detail

Repository
rG FreeBSD src repository
Lint
Lint Passed
Unit
No Test Coverage
Build Status
Buildable 72580
Build 69463: arc lint + arc unit