<feed xmlns='http://www.w3.org/2005/Atom'>
<title>src/usr.bin/patch/util.c, branch release/13.4.0</title>
<subtitle>FreeBSD source tree</subtitle>
<id>https://cgit-dev.freebsd.org/src/atom?h=release%2F13.4.0</id>
<link rel='self' href='https://cgit-dev.freebsd.org/src/atom?h=release%2F13.4.0'/>
<link rel='alternate' type='text/html' href='https://cgit-dev.freebsd.org/src/'/>
<updated>2023-08-23T17:43:22Z</updated>
<entry>
<title>Remove $FreeBSD$: one-line .h pattern</title>
<updated>2023-08-23T17:43:22Z</updated>
<author>
<name>Warner Losh</name>
<email>imp@FreeBSD.org</email>
</author>
<published>2023-08-22T01:31:13Z</published>
<link rel='alternate' type='text/html' href='https://cgit-dev.freebsd.org/src/commit/?id=34041aac835a0bce462bccb7e0239c0ba092f872'/>
<id>urn:sha1:34041aac835a0bce462bccb7e0239c0ba092f872</id>
<content type='text'>
Remove /^\s*\*+\s*\$FreeBSD\$.*$\n/

Similar commit in main:
(cherry picked from commit 42b388439bd3)
</content>
</entry>
<entry>
<title>patch(1): give /dev/null patches special treatment</title>
<updated>2019-11-04T03:07:01Z</updated>
<author>
<name>Kyle Evans</name>
<email>kevans@FreeBSD.org</email>
</author>
<published>2019-11-04T03:07:01Z</published>
<link rel='alternate' type='text/html' href='https://cgit-dev.freebsd.org/src/commit/?id=50dacbf6c2a3d32f7e3f20ca98cda23f38817e7f'/>
<id>urn:sha1:50dacbf6c2a3d32f7e3f20ca98cda23f38817e7f</id>
<content type='text'>
We have a bad habit of duplicating contents of files that are sourced from
/dev/null and applied more than once... take the more sane (in most ways)
GNU route and complain if the file exists and offer reversal options.

This still falls short a little bit as selecting "don't reverse, apply
anyway" will still give you duplicated file contents. There's probably other
issues as well, but awareness is the first step to happiness.

MFC after:	2 weeks
Differential Revision:	https://reviews.freebsd.org/D21535
</content>
</entry>
<entry>
<title>Remove automatic checkout feature.</title>
<updated>2015-08-15T00:42:33Z</updated>
<author>
<name>Xin LI</name>
<email>delphij@FreeBSD.org</email>
</author>
<published>2015-08-15T00:42:33Z</published>
<link rel='alternate' type='text/html' href='https://cgit-dev.freebsd.org/src/commit/?id=e678759c309d8840ca620c77e6a6668b704c3220'/>
<id>urn:sha1:e678759c309d8840ca620c77e6a6668b704c3220</id>
<content type='text'>
Obtained from:	DragonFly via OpenBSD
Relnotes:	yes
MFC:		never
</content>
</entry>
<entry>
<title>patch(1): small include changes.</title>
<updated>2015-04-20T22:15:18Z</updated>
<author>
<name>Pedro F. Giffuni</name>
<email>pfg@FreeBSD.org</email>
</author>
<published>2015-04-20T22:15:18Z</published>
<link rel='alternate' type='text/html' href='https://cgit-dev.freebsd.org/src/commit/?id=df6e4074c09bdc4e6da079bf9f0a03dffd42b482'/>
<id>urn:sha1:df6e4074c09bdc4e6da079bf9f0a03dffd42b482</id>
<content type='text'>
Mostly to match OpenBSD, no functional change.

Obtained from:	OpenBSD
</content>
</entry>
<entry>
<title>Fixes to exit status.</title>
<updated>2014-12-31T16:30:33Z</updated>
<author>
<name>Pedro F. Giffuni</name>
<email>pfg@FreeBSD.org</email>
</author>
<published>2014-12-31T16:30:33Z</published>
<link rel='alternate' type='text/html' href='https://cgit-dev.freebsd.org/src/commit/?id=f718bedc4f28c4407e9b873a356c4d2cffbdfe36'/>
<id>urn:sha1:f718bedc4f28c4407e9b873a356c4d2cffbdfe36</id>
<content type='text'>
Exit with EXIT_FAILURE for invalid arguments.
Fixes NetBSD-PR 43517.

Print version string to stdout instead of stderr;
it is user-requested and not an error.

Obtained from:	NetBSD
MFC after:	5 days
</content>
</entry>
<entry>
<title>patch: Bring in xstrdup and use it when appropriate.</title>
<updated>2014-12-25T21:51:28Z</updated>
<author>
<name>Pedro F. Giffuni</name>
<email>pfg@FreeBSD.org</email>
</author>
<published>2014-12-25T21:51:28Z</published>
<link rel='alternate' type='text/html' href='https://cgit-dev.freebsd.org/src/commit/?id=547e0acbec32a6bb2dc1e75804460ed9fd201d27'/>
<id>urn:sha1:547e0acbec32a6bb2dc1e75804460ed9fd201d27</id>
<content type='text'>
The function savestr allows NULL return values during Plan A patching so in
case of out of memory conditions, Plan B can step in.  In many cases, NULL
value is not properly handled, so use xstrdup here (it's outside Plan A/B
patching, which means that even Plan B relies on successful operations).

Clean up some whitespaces while here

Obtained from:	OpenBSD
MFC after:	2 weeks
</content>
</entry>
<entry>
<title>Improve bsdpatch usability:</title>
<updated>2013-09-26T18:00:45Z</updated>
<author>
<name>Xin LI</name>
<email>delphij@FreeBSD.org</email>
</author>
<published>2013-09-26T18:00:45Z</published>
<link rel='alternate' type='text/html' href='https://cgit-dev.freebsd.org/src/commit/?id=e11cd3bc59ee77f33a2d253d462dac6b3891e6e4'/>
<id>urn:sha1:e11cd3bc59ee77f33a2d253d462dac6b3891e6e4</id>
<content type='text'>
 - Ask only once for "Apply anyway". [1]
 - Tell user what file have failed patch rather than just how
   many hunks failed.

Reported by:	jmg via pfg [1]
Tested by:	pfg [1]
Approved by:	re (gjb)
</content>
</entry>
<entry>
<title>Fix file selection logic for the RCS/SCCS case, as was done for the simple</title>
<updated>2013-09-05T05:51:15Z</updated>
<author>
<name>Stefan Eßer</name>
<email>se@FreeBSD.org</email>
</author>
<published>2013-09-05T05:51:15Z</published>
<link rel='alternate' type='text/html' href='https://cgit-dev.freebsd.org/src/commit/?id=79d8aaa992b25eaf08162efd7eef37bdf9581227'/>
<id>urn:sha1:79d8aaa992b25eaf08162efd7eef37bdf9581227</id>
<content type='text'>
file case before. Bump version because of the changed behavior, which now
matches the documentation.

Reviewed by:	pfg
</content>
</entry>
<entry>
<title>Revert r250972 to fix build.</title>
<updated>2013-05-25T07:17:16Z</updated>
<author>
<name>Glen Barber</name>
<email>gjb@FreeBSD.org</email>
</author>
<published>2013-05-25T07:17:16Z</published>
<link rel='alternate' type='text/html' href='https://cgit-dev.freebsd.org/src/commit/?id=ffca5883e80e522b22c15948e6f7d8eade7c009e'/>
<id>urn:sha1:ffca5883e80e522b22c15948e6f7d8eade7c009e</id>
<content type='text'>
</content>
</entry>
<entry>
<title>The error handling for writes to the target file could lead to the final</title>
<updated>2013-05-24T18:54:52Z</updated>
<author>
<name>Stefan Eßer</name>
<email>se@FreeBSD.org</email>
</author>
<published>2013-05-24T18:54:52Z</published>
<link rel='alternate' type='text/html' href='https://cgit-dev.freebsd.org/src/commit/?id=2360cb0eeab2eae6afc8db630b7b167d19b33d6e'/>
<id>urn:sha1:2360cb0eeab2eae6afc8db630b7b167d19b33d6e</id>
<content type='text'>
fclose() being skipped. Fix this by using boolean "&amp;" and "|" instead of
short-cut operators "&amp;&amp;" and "||".
While here, increment the last part of the version string. The reason is
the fixed output file selection logic in pch.c, which was committed as
r250943, yesterday.

Reviewed by:	pfg
</content>
</entry>
</feed>
