summaryrefslogtreecommitdiffstats
path: root/usr.bin/rcs (follow)
Commit message (Collapse)AuthorAgeFilesLines
* Refuse to remove locked revisions with rcs -orange.joris2020-06-091-1/+9
| | | | | | | Otherwise we could leave behind a lock for a revision that no longer exists, breaking the RCS file. Reported via bugs@ by bernward.pub@arcor.de
* Amend previous fix; joris@ fixed the same bug in OpenCVS's diff3.c r1.47.stsp2019-08-101-2/+4
| | | | | Put the OpenCVS fix, which additionally checks for trailing \n, into OpenRCS. Sync requested by deraadt@ (thanks, I would otherwise have overlooked this)
* Fix merge(1) of files which contain lines with leading dots.stsp2019-08-101-2/+2
| | | | | | | | | | | | A check which tried to detect "dot on a line of its own" in the internal ed script was treating any line with a leading dot as such. Changes made to groups of such lines therefore ended up being truncated in the merged result. "For a random user, there's no shame in being unable to use ed." -- Michael W Lucas ok millert@ deraadt@
* When system calls indicate an error they return -1, not some arbitraryderaadt2019-06-284-14/+14
| | | | | | value < 0. errno is only updated in this case. Change all (most?) callers of syscalls to follow this better, and let's see if this strictness helps us in the future.
* asprintf returns -1, not an arbitrary value < 0. Also upon error thederaadt2019-06-281-2/+2
| | | | | | | (very sloppy specification) leaves an undefined value in *ret, so it is wrong to inspect it, the error condition is enough. discussed a little with nicm, and then much more with millert until we were exasperated
* There was an extra newline in some cases and missing one in others.millert2019-04-261-6/+7
| | | | OK joris@
* new manual page rcsfile(5)schwarze2019-04-242-2/+158
| | | | | | written by Fabio Scotoni <fabio at esse dot ch> with minimal tweaks by me OK jmc@ deraadt@ millert@ on an earlier version
* Delay keyword expansion in co until after the locks have been resolved.joris2019-01-091-39/+40
| | | | | This way the expansion can happen with the correct values and files do not show up as modified.
* When expanding $Log$ make sure a newline is added if rd_log has none.joris2019-01-091-1/+5
| | | | | | This can happen on new RCS files. Fixes $Log$ keyword expansion.
* Make sure rcs_lock_add() and rcs_lock_remove() properly update thejoris2019-01-091-1/+19
| | | | | | | | rd_lock member of the matching delta. Other keyword substitution will not properly work in cases where the RCS file did not have a lock for the revision yet or if the lock is being removed.
* Delete unnecessary <libgen.h> #includesguenther2018-12-301-2/+1
| | | | ok deraadt@
* add some EXIT STATUS sections; from matthew martinjmc2018-06-071-12/+12
|
* improve markup quality in the cases found by the new "--" style messageschwarze2018-03-161-4/+4
|
* add missing HISTORY; based on CVS logs and release announcementsschwarze2017-10-171-7/+16
|
* kill const and string artithmetic related warnings; ok millert@otto2017-08-294-14/+17
|
* Using bitwise OR along with two assignments in the conditional ofmillert2016-10-181-2/+7
| | | | | | a while() loop is a trap for the unwary programmer (albeit a clever trap). Break this up into two separate assignments and using boolean OR for clarity. OK otto@
* Quiet compiler warnings; as applied to usr.bin/cvs by millert@okan2016-10-164-9/+9
| | | | ok millert@
* rlog: add -E and -S options to configure revision separators, tojcs2016-08-312-12/+31
| | | | | | work around commits that might have the default strings in them ok tom deraadt
* Pull in <time.h> for struct tm, used in rcs.hguenther2016-08-2610-11/+21
| | | | ok deraadt@
* The -I flag is documented but not implemented. This fixes that andmillert2016-07-044-18/+24
| | | | | also honors the -I flag from ci/co when prompting like GNU RCS. OK jca@
* Implement Mdocdate keyword substitution.schwarze2016-05-092-2/+14
| | | | | | | In particular, this stops rcsdiff(1) and CVSweb from showing wrong Mdocdate lines in diffs. Problem originally reported by tj@. OK tobias@ otto@ millert@
* fix exit status on pledge(2) failure.gsoares2015-12-291-2/+2
| | | | from jsg@
* Merge xmalloc.[ch] files across base, skipping OpenSSH for now.tobias2015-11-172-14/+9
| | | | ok nicm
* Allow rcsnum_free and buf_free to accept NULL and remove various NULLnicm2015-11-029-68/+40
| | | | checks that are now unnecessary, from Michael W Bombardieri. ok millert
* Style fixes; from Ilya Kalimanmillert2015-10-211-2/+2
|
* Implement real "flock" request and add it to userland programs thatmillert2015-10-161-2/+2
| | | | use pledge and file locking. OK deraadt@
* normalize a few more tame request orderings, to help reviewderaadt2015-10-101-2/+2
|
* pledge "stdio getpw rpath wpath cpath fattr". doug pointed out getpw*deraadt2015-10-101-1/+4
| | | | | use, and fattr for chmod. doug
* fix the spacing of -m in the SYNOPSISschwarze2015-09-251-4/+3
|
* Add brackets to clarify assignments that are the result of a test operator.jsg2015-09-051-2/+2
| | | | ok deraadt@ looks correct millert@ jung@
* Avoid unintended problems with operator precedence when doing anjsg2015-09-051-2/+2
| | | | | | assignment and comparison. ok deraadt@ looks correct millert@ jung@
* Use strdup in xstrdup; from Fritjof Bornebusch.nicm2015-06-171-6/+3
|
* Remove NULL check before free; Fritjof Bornebusch.nicm2015-06-171-3/+2
|
* Convert xfree to free. From Fritjof Bornebusch. ok deraadtnicm2015-06-1315-176/+125
|
* Use the (new) function name in errx() after its rename in r1.6.okan2015-03-261-2/+2
| | | | ok bcallah@
* Include stdint.h, not limits.h to get SIZE_MAX. OK guenther@millert2015-02-052-3/+4
|
* Replace <sys/param.h> with <limits.h> and other less dirty headers wherederaadt2015-01-1613-42/+51
| | | | | | | | | possible. Annotate <sys/param.h> lines with their current reasons. Switch to PATH_MAX, NGROUPS_MAX, HOST_NAME_MAX+1, LOGIN_NAME_MAX, etc. Change MIN() and MAX() to local definitions of MINIMUM() and MAXIMUM() where sensible to avoid pulling in the pollution. These are the files confirmed through binary verification. ok guenther, millert, doug (helped with the verification protocol)
* An internal function called xrealloc() is actually a fail-hardderaadt2014-12-0110-44/+36
| | | | reallocarray()... so rename it.
* consistency in calling usage, from Fritjof Bornebuschotto2014-11-281-2/+2
|
* not compiled before commitderaadt2014-11-221-2/+2
|
* Fixed uninitialized pointer (and other struct entries while at it)tobias2014-11-221-2/+2
| | | | | | | | which is referenced while parsing invalid RCS files. Spotted by jsg. ok deraadt
* Convert the logic in rcsparse_warnx(). Instead of creating abluhm2014-11-161-8/+9
| | | | | | | | temporary format string, create a temporary message. If there is not enough memory to log the error, just log this second error. The double error path gets never tested, so it should be simple. Make it work like the other places. OK doug@
* Zap some stored values never read; From Fritjof Bornebusch; ok nicm@otto2014-10-108-19/+11
|
* Explicitly handle -l and -u combinations. From Fritjof Bornebusch; ok daniel@otto2014-10-101-3/+7
|
* exit in usage functions themselves; from Fritjof Bornebusch; ok nicm@otto2014-10-0210-65/+60
|
* atoi to strtonum; from Fritjof Bornebusch; ok nicm@otto2014-09-301-6/+7
|
* Use %zu where appropriate, from Fritjof Bornebusch.otto2014-09-271-7/+7
|
* use calloc, from Benjamin Baiertedu2014-05-291-5/+3
|
* Plug a small memory leak: if we pass checkin_init/checkin_updatejca2014-05-191-2/+3
| | | | | a revision thru pb.newrev, it will not be freed. From Fritjof Bornebusch, no objections from tech@
* fix a test for invalid timezonesjsg2014-04-291-2/+2
| | | | oks from a bunch of people