<feed xmlns='http://www.w3.org/2005/Atom'>
<title>src/usr.bin/diff/tests, branch release/13.1.0</title>
<subtitle>FreeBSD source tree</subtitle>
<id>https://cgit-dev.freebsd.org/src/atom?h=release%2F13.1.0</id>
<link rel='self' href='https://cgit-dev.freebsd.org/src/atom?h=release%2F13.1.0'/>
<link rel='alternate' type='text/html' href='https://cgit-dev.freebsd.org/src/'/>
<updated>2021-09-25T08:34:39Z</updated>
<entry>
<title>diff: read whole files to determine if they are ASCII text</title>
<updated>2021-09-25T08:34:39Z</updated>
<author>
<name>Piotr Pawel Stefaniak</name>
<email>pstef@FreeBSD.org</email>
</author>
<published>2021-08-22T19:57:13Z</published>
<link rel='alternate' type='text/html' href='https://cgit-dev.freebsd.org/src/commit/?id=bda949b6efdf099846775d3dc595c36561df1cca'/>
<id>urn:sha1:bda949b6efdf099846775d3dc595c36561df1cca</id>
<content type='text'>
Before this change, only the first BUFSIZE bytes were checked.

(cherry picked from commit 3cbf98e2bee91db9ed9118ff557e02cdd449f49a)
</content>
</entry>
<entry>
<title>diff: don't output carriage returns that were stripped on input</title>
<updated>2021-09-25T08:34:38Z</updated>
<author>
<name>Piotr Pawel Stefaniak</name>
<email>pstef@FreeBSD.org</email>
</author>
<published>2021-08-22T16:05:59Z</published>
<link rel='alternate' type='text/html' href='https://cgit-dev.freebsd.org/src/commit/?id=ece58f7ada409ac68e072cdddcc29e21127aafce'/>
<id>urn:sha1:ece58f7ada409ac68e072cdddcc29e21127aafce</id>
<content type='text'>
--strip-trailing-cr worked as intended for comparison between files,
but the characters were still present in final output.

(cherry picked from commit af2f0164318455433db95adce07af829285b78ad)
</content>
</entry>
<entry>
<title>diff: Use unprivileged_user with report_identical test</title>
<updated>2021-08-22T16:48:55Z</updated>
<author>
<name>Olivier Cochard</name>
<email>olivier@FreeBSD.org</email>
</author>
<published>2021-02-03T16:18:59Z</published>
<link rel='alternate' type='text/html' href='https://cgit-dev.freebsd.org/src/commit/?id=108633bb1556f1e107b05a68fa0c323ac4d2c712'/>
<id>urn:sha1:108633bb1556f1e107b05a68fa0c323ac4d2c712</id>
<content type='text'>
Approved by:	bapt
Sponsored by:	Netflix
Differential Revision:	https://reviews.freebsd.org/D28466

(cherry picked from commit b67df8d7c203a139b5afbe72e1947fbb8c32dc73)
</content>
</entry>
<entry>
<title>diff: add a test case about the non regular file support</title>
<updated>2021-05-05T08:37:07Z</updated>
<author>
<name>Baptiste Daroussin</name>
<email>bapt@FreeBSD.org</email>
</author>
<published>2021-01-26T10:38:36Z</published>
<link rel='alternate' type='text/html' href='https://cgit-dev.freebsd.org/src/commit/?id=07d72ca90585ee98dbdd8f4fd2bb01bc2329d99c'/>
<id>urn:sha1:07d72ca90585ee98dbdd8f4fd2bb01bc2329d99c</id>
<content type='text'>
(cherry picked from commit c440e7870a020546ad241848e2ff8e9cb27a3073)
</content>
</entry>
<entry>
<title>diff: add a test case for failed -s option</title>
<updated>2021-02-01T13:05:24Z</updated>
<author>
<name>Baptiste Daroussin</name>
<email>bapt@FreeBSD.org</email>
</author>
<published>2021-01-25T17:40:12Z</published>
<link rel='alternate' type='text/html' href='https://cgit-dev.freebsd.org/src/commit/?id=0702bf9c495d517ef30432de1990f9a301598942'/>
<id>urn:sha1:0702bf9c495d517ef30432de1990f9a301598942</id>
<content type='text'>
(cherry picked from commit 13860e71eb501f498a2263f44ea9244f6830b61c)
</content>
</entry>
<entry>
<title>diff: honour flags with -q</title>
<updated>2021-01-09T18:34:06Z</updated>
<author>
<name>Ed Maste</name>
<email>emaste@FreeBSD.org</email>
</author>
<published>2021-01-09T16:22:28Z</published>
<link rel='alternate' type='text/html' href='https://cgit-dev.freebsd.org/src/commit/?id=12a8d3027d414abd15798de1b6d8b01151bdac50'/>
<id>urn:sha1:12a8d3027d414abd15798de1b6d8b01151bdac50</id>
<content type='text'>
Previously -q (just print a line when files differ) ignored flags like
-w (ignore whitespace).  Avoid the D_BRIEF short-circuit when flags are
in effect.

PR:		252515
Reported by:	Scott Aitken
Reviewed by:	kevans
MFC after:	1 week
Sponsored by:	The FreeBSD Foundation
Differential Revision: https://reviews.freebsd.org/D28064
</content>
</entry>
<entry>
<title>diff: fix side_by_side after r363679</title>
<updated>2020-07-30T13:33:45Z</updated>
<author>
<name>Kyle Evans</name>
<email>kevans@FreeBSD.org</email>
</author>
<published>2020-07-30T13:33:45Z</published>
<link rel='alternate' type='text/html' href='https://cgit-dev.freebsd.org/src/commit/?id=ac05de17883d6981f9ff3d52154ec336203fc683'/>
<id>urn:sha1:ac05de17883d6981f9ff3d52154ec336203fc683</id>
<content type='text'>
It's currently unclear to me how this could have worked previously; \n here
is not a literal newline but actual '\' 'n', and was getting passed to the
underlying regex engine as such. regex(3) does not translate this to a
newline, and this became an error because we don't really allow escaping
of arbitrary ordinary characters anymore.

Run the pattern strings through printf to make sure we're dealing with real
newlines before passing them through to atf_check, which ultimately feeds
them directly to regcomp(3).

This fix is different than that will be needed for sed, in that this is the
proper way to inject newlines into search strings as long as regex(3)
won't combine \ + n as folks might expect.

Reported by:	Jenkins via lwhsu
MFC after:	1 week
</content>
</entry>
<entry>
<title>diff: restore compatibility with GNU diff regarding -N option</title>
<updated>2020-06-01T09:09:36Z</updated>
<author>
<name>Baptiste Daroussin</name>
<email>bapt@FreeBSD.org</email>
</author>
<published>2020-06-01T09:09:36Z</published>
<link rel='alternate' type='text/html' href='https://cgit-dev.freebsd.org/src/commit/?id=2816b9998c649dce97c132b8365ca697040b4c41'/>
<id>urn:sha1:2816b9998c649dce97c132b8365ca697040b4c41</id>
<content type='text'>
When -N is used the missing files are treated as empty.

PR:		233402
Submitted by:	Fehmi Noyan Isi &lt;fnoyanisi@yahoo.com&gt;
Reported by:	Roman Neuhauser &lt;roman@sigpipe.cz&gt;
MFC after:	3 days
Differential Revision:	D25081
</content>
</entry>
<entry>
<title>Restore compatibility with GNU diff regarding --label</title>
<updated>2020-06-01T09:01:13Z</updated>
<author>
<name>Baptiste Daroussin</name>
<email>bapt@FreeBSD.org</email>
</author>
<published>2020-06-01T09:01:13Z</published>
<link rel='alternate' type='text/html' href='https://cgit-dev.freebsd.org/src/commit/?id=f096ed981fe534c36ed8662ef307042123e443f3'/>
<id>urn:sha1:f096ed981fe534c36ed8662ef307042123e443f3</id>
<content type='text'>
Various options to "diff(1)" show filenames, and traditionally make use of the
"--label" parameter, if set.

Restore this behaviour in BSD diff.

While here add a regression test

PR:		244533
Submitted by:	Jamie Landeg-Jones &lt;jamie@catflap.org&gt;
MFC after:	3 days
</content>
</entry>
<entry>
<title>diff(1): don't reject specifying the same format multiple times</title>
<updated>2020-04-28T14:33:33Z</updated>
<author>
<name>Kyle Evans</name>
<email>kevans@FreeBSD.org</email>
</author>
<published>2020-04-28T14:33:33Z</published>
<link rel='alternate' type='text/html' href='https://cgit-dev.freebsd.org/src/commit/?id=67c907653e3cfcc807c96e3419bacce3b5479f1c'/>
<id>urn:sha1:67c907653e3cfcc807c96e3419bacce3b5479f1c</id>
<content type='text'>
This may happen, for instance, if one happens to have an alias of diff to
diff -up and attempts to specify the amount of context on top of that.

Aliases like this may cause other problems, but if they're really not ever
generating non-unified diffs then we should at least not break that
use-case.

In addition, we'll now pick up a format mismatch if -p is specified with
!contextual &amp;&amp; !unified &amp;&amp; !unset.

Fix up a small trailing whitespace nit in the tests while we're here, and
add tests to make sure that we can double up all the formatting options.

Reported by:	jbeich
MFC after:	3 days
</content>
</entry>
</feed>
