summaryrefslogtreecommitdiff
path: root/usr.bin/rcs/rcsdiff.c
AgeCommit message (Collapse)Author
2007-04-26the message returned by usage() must fit on a 80-column displayIgor Sobrado
ok by jmc@, niallo@, and xsa@
2007-02-27As done in OpenCVS, general includes cleanup sweep. OK otto@.Xavier Santolaria
2006-10-12- convert some warnx() to warn(), which fixes a few stupidly un-informative ↵Niall O'Higgins
error messages (found by tom@) - make rcs_choosefile() save wrt errno, input from ray@ ok joris@ xsa@
2006-09-22- explain diff_options (which i renamed from "diff options")Jason McIntyre
- sync usage() ok xsa
2006-09-21Add support to rcsdiff for all the other diff flags thatTodd C. Miller
are pertinent to files (not directories) and that do not conflict with rcsdiff-specific flags. OK xsa@
2006-07-31Minor KNF.Ray Lai
OK xsa@
2006-07-08Remove file mode argument from {cvs|rcs}_buf_write_stmp(). WeRay Lai
always set the temporary file to mode 600, which is already done by mkstemp(). OK joris@ and xsa@ over a month ago.
2006-06-04- initialise path pointers to NULL since error code checks for that.Niall O'Higgins
2006-05-27Remove rcs_statfile(). It was just a wrapper for rcs_choosefile(),Ray Lai
handling exceptions oddly. OK joris@
2006-05-09Remove /* NOTREACHED */ comments, now that lint is smart aboutRay Lai
__dead. I never should have put them there. OK xsa@.
2006-05-08err() and errx() should also exit with status 2;Xavier Santolaria
2006-05-08exit with status 2 after usage() too; pointed out by uwe@.Xavier Santolaria
2006-05-05- fix rcsdiff exit status on success/errors; now matches gnu/usr.bin/rcs.Xavier Santolaria
- add DIAGNOSTICS section to rcsdiff.1 wrt exit codes. ok ray@ and jmc@ for man page bits.
2006-05-04finish work wrt TMPDIR; use xasprintf() to simplify code while in there;Xavier Santolaria
"looks fine" ray@.
2006-04-29Check return values for all strlcpy, and strlcat calls.Ray Lai
OK xsa@ and probably others.
2006-04-26prevent file races by obtaining an fd for the RCS file andJoris Vink
do our operations on that, this is safe and guarantees we can operate on the file until we close(2) it. a fix is coming for the remaining races in our diff code. okay niallo@ and ray@
2006-04-26fork our code we shared between openrcs/cvs into the openrcs dir.Joris Vink
this was starting to become inhuman to maintain without ugly ugly hacks in the shared code, and it will be easier to make specific changes for openrcs without touching the soon-to-be-replaced opencvs code.
2006-04-25fatal() -> err()/errx() as we try to not depend on heavy cvs_log().Xavier Santolaria
OK joriski.
2006-04-24make the -r description match that in rcsmerge(1), as far as is possible;Jason McIntyre
ok xsa
2006-04-24be consistent in error messages for wrongly specified keyword substitutionXavier Santolaria
mode for `-k'.
2006-04-21move shared functions into rcsutil.[ch]; this makes rcsprog.c cleaner;Xavier Santolaria
"the voices in my head say OK!" joris@.
2006-04-21remove overkill cvs_log() and rather use warn()/warnx().Xavier Santolaria
OK ray@ and discussed with joris@.
2006-04-19switch -q handling to bitwise flags; OK ray@ niallo@.Xavier Santolaria
2006-04-14spacesTheo de Raadt
2006-04-14- don't append the extension if it's already there (PR 5076).Joris Vink
- show magic branches in rlog (thanks for that nicer hack niall). - correct output in rcsdiff, so we perfectly match gnu's all these bugs were found by sturm@ while he was using cvsweb (which uses the RCS tools). "it is in my view that you should put it in" niallo@
2006-04-13clean up temporary files when we finish running.Joris Vink
"cool" niallo@
2006-04-13*** empty log message ***Ray Lai
2006-04-12Clean up <rev> handling. Whenever a revision is specified after aRay Lai
flag, it calls one of two new functions: rcs_setrevstr() or rcs_setrevstr2(). rcs_setrevstr() sets a string to another string, and complains if it was set more than once. rcs_setrevstr2() takes two strings, sets one after the other, and fatal()s if more than two strings were given. All <rev> handling is now done in the loop that goes through each argv. This is necessary for parsing symbols, which will be much easier after this. Along the way a lot of memory leaks were cleaned up. There is one area where rcs_set_rev() is called, which allocates a RCSNUM and stores it in pb.newrev, but it segfaults whenever I try to rcsnum_free() it. I put an /* XXX */ comment there for now. Passes regression tests and the code is less complicated in some ways (to me). Suggestions and OK xsa@
2006-04-10make sure we add the correct name mkstemp(3) creates for usJoris Vink
to the worklist of temporary files. this way we definatly don't leave any files behind in /tmp. tested & okay niallo@
2006-04-10change rcs_kwexp_set() return type to void and simplify its use. OK niallo@.Xavier Santolaria
2006-04-06-z can take no argument.Xavier Santolaria
2006-03-30add temporary files to the worklist before creating them, this preventsJoris Vink
a race when the user would interrupt the program when it was returning from cvs_buf_write_stmp() and leave the temporary files behind.
2006-03-24Allow the -x flag to be used without an extension.Ray Lai
``that makes sense'' xsa@
2006-03-20delint; cvs_buf_write_stmp() will never return non-zero:Niall O'Higgins
- remove superfluous error handling for cvs_buf_write_stmp() - change cvs_buf_write_stmp() return type to void ok joris@ xsa@
2006-03-16Follow exit() with /* NOTREACHED*/ for lint.Ray Lai
``OK niallo@'' niallo@
2006-03-15- zap filename arg in rcsdiff_rev() since its not used.Niall O'Higgins
ok ray@
2006-03-08make openrcs use the worklist framework to keep track of temporary filesJoris Vink
and remove them in case it gets interrupted. suggested by deraadt@, ok niallo@
2006-03-07-z support for RCS;Joris Vink
2006-03-06update usage();Jason McIntyre
2006-03-06move compat flags into a STANDARDS section;Jason McIntyre
2006-03-06fix output to mimic gnu/usr.bin/rcs.Xavier Santolaria
2006-03-06many spacing cleanupsTheo de Raadt
2006-03-05now that rcs_getrev() isn't doing keyword expansion anymore and rcsdiff(1)Niall O'Higgins
expects to be comparing files with expanded keywords, we need to add a couple of calls to rcs_kwexp_buf() to rcsdiff.c. two minor output fixes in this diff also. ok xsa@ eyeballed by Rai Lai
2006-01-05cleanup, move log.h and rcs.h inclusion into rcsprog.h;Xavier Santolaria
2006-01-02#include's cleanup; ok joris@ niallo@.Xavier Santolaria
2005-12-27- implement lazy-parsing of rcs files, that is only parse as much as weNiall O'Higgins
need. this can save us much work, particularly with very large rcs files. first of a few important performance improvements. ok joris@
2005-12-20spread the use of fatal();Xavier Santolaria
2005-12-10- its wrong to use exit() here; return instead.Niall O'Higgins
ok joris@
2005-12-05kill unused var;Xavier Santolaria
2005-12-01- fix up context and unified diff output in both open rcs and open cvs soNiall O'Higgins
that the date is set correctly. ok joris@