Page MenuHomeFreeBSD

Fix etcupdate diff with POSIXLY_CORRECT set, add option to list changes files
ClosedPublic

Authored by lytboris_gmail.com on Apr 29 2026, 11:07 AM.
Tags
None
Referenced Files
F174264119: D56708.id176892.diff
Thu, Oct 1, 8:33 PM
F174258913: D56708.diff
Thu, Oct 1, 7:33 PM
F174187282: D56708.id176775.diff
Thu, Oct 1, 5:51 AM
Unknown Object (File)
Wed, Sep 30, 11:07 PM
Unknown Object (File)
Tue, Sep 29, 1:26 AM
Unknown Object (File)
Mon, Sep 28, 6:50 PM
Unknown Object (File)
Sat, Sep 26, 8:21 AM
Unknown Object (File)
Thu, Sep 24, 6:38 AM
Subscribers

Details

Summary

etcupdate diff fails to show any diffs when POSIXLY_CORRECT environment variable is set. Instead of showing a diff, etcupdate diff emits diff --help for each file that was altered locally. This happens due to misplacement of the second -L argument of diff command, it is treated by getopt_long as an error.

This proposal fixes this behavior simply moving the second -L argument into a proper place.

A new feature comes along with this fix: -l argument for a diff command alters the way it shows differences. Instead of printing full diff, it reports changed file the same way as added/removed files are reported.

Diff Detail

Repository
rG FreeBSD src repository
Lint
Lint Skipped
Unit
Tests Skipped