opnsense-src/usr.bin/diff
Dag-Erling Smørgrav da29052897 diff: Fix --expand-tabs and --side-by-side.
* Overhaul column width and padding calculation.
* Rewrite print_space() so it is now a) correct and b) understandable.
* Rewrite tab expansion in fetch() for the same reason.

This brings us in line with GNU diff for all cases I could think of.

Sponsored by:	Klara, Inc.
Reviewed by:	imp
Differential Revision:	https://reviews.freebsd.org/D44014

(cherry picked from commit 53de23f4d140becc3166e87665b0064f215a220e)

diff: Bump manual page date.

Sponsored by:	Klara, Inc.

(cherry picked from commit 312b1076c6b0aff9bbcaff058b93385eaf607685)
2024-03-11 13:19:06 +01:00
..
tests Remove $FreeBSD$: one-line sh pattern 2023-08-16 11:55:03 -06:00
diff.1 diff: Fix --expand-tabs and --side-by-side. 2024-03-11 13:19:06 +01:00
diff.c diff: Fix --expand-tabs and --side-by-side. 2024-03-11 13:19:06 +01:00
diff.h Remove $FreeBSD$: one-line .h pattern 2023-08-16 11:54:23 -06:00
diffdir.c Remove $FreeBSD$: one-line .c pattern 2023-08-16 11:54:42 -06:00
diffreg.c diff: Fix --expand-tabs and --side-by-side. 2024-03-11 13:19:06 +01:00
Makefile Remove $FreeBSD$: one-line sh pattern 2023-08-16 11:55:03 -06:00
pr.c Remove $FreeBSD$: one-line .c pattern 2023-08-16 11:54:42 -06:00
pr.h Remove $FreeBSD$: two-line .h pattern 2023-08-16 11:54:16 -06:00
TODO Update diff(1) TODO removing what has been implemented 2020-02-07 10:18:01 +00:00
xmalloc.c Remove $FreeBSD$: one-line .c pattern 2023-08-16 11:54:42 -06:00
xmalloc.h Remove $FreeBSD$: two-line .h pattern 2023-08-16 11:54:16 -06:00