OpenBSD CVS

CVS log for src/usr.bin/cvs/diff.c


[BACK] Up to [local] / src / usr.bin / cvs

Request diff between arbitrary revisions


Default branch: MAIN


Revision 1.164 / (download) - annotate - [select for diffs], Sun Oct 24 21:24:16 2021 UTC (2 years, 6 months ago) by deraadt
Branch: MAIN
CVS Tags: OPENBSD_7_5_BASE, OPENBSD_7_5, OPENBSD_7_4_BASE, OPENBSD_7_4, OPENBSD_7_3_BASE, OPENBSD_7_3, OPENBSD_7_2_BASE, OPENBSD_7_2, OPENBSD_7_1_BASE, OPENBSD_7_1, HEAD
Changes since 1.163: +3 -3 lines
Diff to previous 1.163 (colored)

For open/openat, if the flags parameter does not contain O_CREAT, the
3rd (variadic) mode_t parameter is irrelevant.  Many developers in the past
have passed mode_t (0, 044, 0644, or such), which might lead future people
to copy this broken idiom, and perhaps even believe this parameter has some
meaning or implication or application. Delete them all.
This comes out of a conversation where tb@ noticed that a strange (but
intentional) pledge behaviour is to always knock-out high-bits from
mode_t on a number of system calls as a safety factor, and his bewilderment
that this appeared to be happening against valid modes (at least visually),
but no sorry, they are all irrelevant junk.  They could all be 0xdeafbeef.
ok millert

Revision 1.163 / (download) - annotate - [select for diffs], Thu Jun 1 08:08:24 2017 UTC (6 years, 11 months ago) by joris
Branch: MAIN
CVS Tags: OPENBSD_7_0_BASE, OPENBSD_7_0, OPENBSD_6_9_BASE, OPENBSD_6_9, OPENBSD_6_8_BASE, OPENBSD_6_8, OPENBSD_6_7_BASE, OPENBSD_6_7, OPENBSD_6_6_BASE, OPENBSD_6_6, OPENBSD_6_5_BASE, OPENBSD_6_5, OPENBSD_6_4_BASE, OPENBSD_6_4, OPENBSD_6_3_BASE, OPENBSD_6_3, OPENBSD_6_2_BASE, OPENBSD_6_2
Changes since 1.162: +4 -5 lines
Diff to previous 1.162 (colored)

Stop looking at current_cvsroot->cr_method to figure out if we're remote or not.

Instead use cvsroot_is_local() and cvsroot_is_remote().

Revision 1.162 / (download) - annotate - [select for diffs], Thu Oct 13 20:51:25 2016 UTC (7 years, 7 months ago) by fcambus
Branch: MAIN
CVS Tags: OPENBSD_6_1_BASE, OPENBSD_6_1
Changes since 1.161: +3 -3 lines
Diff to previous 1.161 (colored)

rcsnum_free() -> free() cleanups. From Michael W. Bombardieri.

OK millert@

Revision 1.161 / (download) - annotate - [select for diffs], Thu Nov 5 09:48:21 2015 UTC (8 years, 6 months ago) by nicm
Branch: MAIN
CVS Tags: OPENBSD_6_0_BASE, OPENBSD_6_0, OPENBSD_5_9_BASE, OPENBSD_5_9
Changes since 1.160: +5 -7 lines
Diff to previous 1.160 (colored)

Remove xfree(), like already done for RCS. From Michael W Bombardieri,
ok mmcc

Revision 1.160 / (download) - annotate - [select for diffs], Wed Apr 20 18:33:13 2011 UTC (13 years, 1 month ago) by nicm
Branch: MAIN
CVS Tags: OPENBSD_5_8_BASE, OPENBSD_5_8, OPENBSD_5_7_BASE, OPENBSD_5_7, OPENBSD_5_6_BASE, OPENBSD_5_6, OPENBSD_5_5_BASE, OPENBSD_5_5, OPENBSD_5_4_BASE, OPENBSD_5_4, OPENBSD_5_3_BASE, OPENBSD_5_3, OPENBSD_5_2_BASE, OPENBSD_5_2, OPENBSD_5_1_BASE, OPENBSD_5_1, OPENBSD_5_0_BASE, OPENBSD_5_0
Changes since 1.159: +2 -2 lines
Diff to previous 1.159 (colored)

Use -u when diff context is 3, from Michael W Bombardieri, tweaked by
millert.

Revision 1.159 / (download) - annotate - [select for diffs], Fri Jul 30 21:47:18 2010 UTC (13 years, 9 months ago) by ray
Branch: MAIN
CVS Tags: OPENBSD_4_9_BASE, OPENBSD_4_9, OPENBSD_4_8_BASE, OPENBSD_4_8
Changes since 1.158: +5 -3 lines
Diff to previous 1.158 (colored)

Check date_parse return values.

OK xsa

Revision 1.158 / (download) - annotate - [select for diffs], Wed Jul 28 21:19:30 2010 UTC (13 years, 9 months ago) by nicm
Branch: MAIN
Changes since 1.157: +31 -4 lines
Diff to previous 1.157 (colored)

Support -U and -C to specify the context length for "cvs diff".

This doesn't alter cvs rdiff, where -U and -C are not support by GNU
cvs.

ok sthen zinovik

Revision 1.157 / (download) - annotate - [select for diffs], Fri Jul 23 21:46:05 2010 UTC (13 years, 9 months ago) by ray
Branch: MAIN
Changes since 1.156: +6 -6 lines
Diff to previous 1.156 (colored)

Reduce variable/function name and whitespace differences between
cvs/rcs.

OK xsa zinovik

Revision 1.156 / (download) - annotate - [select for diffs], Fri Jul 23 08:31:19 2010 UTC (13 years, 9 months ago) by ray
Branch: MAIN
Changes since 1.155: +2 -2 lines
Diff to previous 1.155 (colored)

Rename a bunch of variables and functions, removing the cvs_/rcs_
prefixes to reduce differences between cvs and rcs files.

"yes!" nicm

Revision 1.155 / (download) - annotate - [select for diffs], Sun Jun 7 08:39:13 2009 UTC (14 years, 11 months ago) by ray
Branch: MAIN
CVS Tags: OPENBSD_4_7_BASE, OPENBSD_4_7, OPENBSD_4_6_BASE, OPENBSD_4_6
Changes since 1.154: +2 -2 lines
Diff to previous 1.154 (colored)

More cvs/diff/rcs convergence:
1. Mostly variable/function renaming, SIZE_T_MAX->SIZE_MAX, and
spacing.
2. One strchr -> strncspn.
3. diff had a weird thing where it set file[12] = ofile[12] but
never updated file or ofile, then if file and ofile were different
it freed it. I removed it.

OK millert

Revision 1.154 / (download) - annotate - [select for diffs], Sat Jun 6 14:17:27 2009 UTC (14 years, 11 months ago) by ray
Branch: MAIN
Changes since 1.153: +15 -10 lines
Diff to previous 1.153 (colored)

Sync some rcsdiff changes to cvsdiff.  As a side effect,
cvs diff -t now works.  There should be no functional change
otherwise.

OK millert

Revision 1.153 / (download) - annotate - [select for diffs], Wed Apr 29 12:56:15 2009 UTC (15 years ago) by joris
Branch: MAIN
Changes since 1.152: +2 -2 lines
Diff to previous 1.152 (colored)

add options 'a' and 'd' to the getopt string so
we can actually use them.

bad sthen@ and bad me for missing this :)

Revision 1.152 / (download) - annotate - [select for diffs], Tue Apr 28 09:05:40 2009 UTC (15 years ago) by sthen
Branch: MAIN
Changes since 1.151: +19 -3 lines
Diff to previous 1.151 (colored)

support some additional diff options: -a, -b, -d, -w
ok joris@

Revision 1.151 / (download) - annotate - [select for diffs], Fri Apr 3 19:46:56 2009 UTC (15 years, 1 month ago) by joris
Branch: MAIN
Changes since 1.150: +6 -1 lines
Diff to previous 1.150 (colored)

i fucked up last night, bad so partially revert a piece of
code that wasnt suppose to dissapear:

for uptodate files, we want to compare rev1 against
file_rcsrev to see if we wish to diff or not. saves a bit off logic.

commited with opencvs,
permission by deraadt@

Revision 1.150 / (download) - annotate - [select for diffs], Fri Apr 3 08:18:44 2009 UTC (15 years, 1 month ago) by joris
Branch: MAIN
Changes since 1.149: +1 -4 lines
Diff to previous 1.149 (colored)

my last commit to diff.c broke diffing in some cases,
noticed the hard way here at work.

commiting with opencvs,
permission by deraadt@

Revision 1.149 / (download) - annotate - [select for diffs], Thu Apr 2 21:13:50 2009 UTC (15 years, 1 month ago) by joris
Branch: MAIN
Changes since 1.148: +24 -16 lines
Diff to previous 1.148 (colored)

properly deal with uptodate files server-side, as they do not
have a file on disk we'll need to load the revision into
a temporary file to do our comparison.

do not even bother trying diffing 2 off the same revisions
either. causes less noise... way less.

you guessed it, commited using opencvs entirely.
with permission from deraadt@

Revision 1.148 / (download) - annotate - [select for diffs], Thu Apr 2 09:09:40 2009 UTC (15 years, 1 month ago) by joris
Branch: MAIN
Changes since 1.147: +2 -1 lines
Diff to previous 1.147 (colored)

make sure diffing -rTAG -rTAG works even if files are uptodate

commited with opencvs,
with permission by deraadt@

Revision 1.147 / (download) - annotate - [select for diffs], Mon Mar 23 07:28:05 2009 UTC (15 years, 2 months ago) by joris
Branch: MAIN
Changes since 1.146: +3 -4 lines
Diff to previous 1.146 (colored)

any directory messages are, believe it or not, suppose to go to LP_ERR
instead of LP_NOTICE, while here modify output for non-existing
files to match "? foobar" instead of "cannot find foobar".

makes our output a little less alien and a little bit more gnuish.

Revision 1.146 / (download) - annotate - [select for diffs], Thu Mar 19 10:09:16 2009 UTC (15 years, 2 months ago) by joris
Branch: MAIN
Changes since 1.145: +4 -1 lines
Diff to previous 1.145 (colored)

do not diff files server-side that are uptodate but require a patch,
as the client does not provide these files at all because they are
not modified in anyway. otherwise this results in bad mojo.

found by myself and sthen@

Revision 1.145 / (download) - annotate - [select for diffs], Sat Feb 21 14:50:53 2009 UTC (15 years, 2 months ago) by joris
Branch: MAIN
CVS Tags: OPENBSD_4_5_BASE, OPENBSD_4_5
Changes since 1.144: +7 -7 lines
Diff to previous 1.144 (colored)

use FILE_ON_DISK flags when we need to verify if a file
exists in the working copy or not instead of checking fd being -1
since this can differ in server or local mode.

Revision 1.144 / (download) - annotate - [select for diffs], Fri Jun 20 14:04:29 2008 UTC (15 years, 11 months ago) by tobias
Branch: MAIN
CVS Tags: OPENBSD_4_4_BASE, OPENBSD_4_4
Changes since 1.143: +12 -2 lines
Diff to previous 1.143 (colored)

Properly send -D arguments to server when run as a client.  Issue spotted
by sthen.

ok joris

Revision 1.143 / (download) - annotate - [select for diffs], Fri Jun 20 13:59:14 2008 UTC (15 years, 11 months ago) by tobias
Branch: MAIN
Changes since 1.142: +12 -6 lines
Diff to previous 1.142 (colored)

If -N has been specified along -D for diff, treat invalid dates as non-existent file.  Spotted by sthen.  ok joris

Revision 1.142 / (download) - annotate - [select for diffs], Tue Jun 17 06:38:21 2008 UTC (15 years, 11 months ago) by joris
Branch: MAIN
Changes since 1.141: +2 -2 lines
Diff to previous 1.141 (colored)

unbreak diff for newly added files, tsk.

Revision 1.141 / (download) - annotate - [select for diffs], Sat Jun 14 04:34:08 2008 UTC (15 years, 11 months ago) by tobias
Branch: MAIN
Changes since 1.140: +7 -1 lines
Diff to previous 1.140 (colored)

Conforming to RCS specification, it is possible but unlikely to encounter
an RCS file which has no head revision set.  Some commands actually can
work with them (log, status) so support these files. Fixes  A LOT of
possible segmentation faults.

ok joris

Revision 1.140 / (download) - annotate - [select for diffs], Wed Jun 11 20:55:34 2008 UTC (15 years, 11 months ago) by joris
Branch: MAIN
Changes since 1.139: +4 -4 lines
Diff to previous 1.139 (colored)

do not count on files that are uptodate to be on disk in a remote setup.

Revision 1.139 / (download) - annotate - [select for diffs], Wed Jun 11 02:19:13 2008 UTC (15 years, 11 months ago) by tobias
Branch: MAIN
Changes since 1.138: +7 -6 lines
Diff to previous 1.138 (colored)

Avoid possible NULL pointer dereferences by using reentrant versions
of time functions.

ok joris

Revision 1.138 / (download) - annotate - [select for diffs], Tue Jun 10 17:34:36 2008 UTC (15 years, 11 months ago) by tobias
Branch: MAIN
Changes since 1.137: +7 -5 lines
Diff to previous 1.137 (colored)

Omit "cannot find file" on server-side if client runs "diff" on an up-to-date
file, because it won't be sent to server then.

ok joris

Revision 1.137 / (download) - annotate - [select for diffs], Fri May 30 11:06:17 2008 UTC (15 years, 11 months ago) by tobias
Branch: MAIN
Changes since 1.136: +45 -12 lines
Diff to previous 1.136 (colored)

diff -D support, also a change in diff_internals to properly print
file name or /dev/null, if file has been removed or added.

Revision 1.136 / (download) - annotate - [select for diffs], Fri May 30 10:12:12 2008 UTC (15 years, 11 months ago) by tobias
Branch: MAIN
Changes since 1.135: +170 -140 lines
Diff to previous 1.135 (colored)

Major rework of our cvs diff implementation fixes tons of GNU cvs
compatibility glitches and bugs which have been spotted by ray@ and
Igor Zinovik.

ok joris

Revision 1.135 / (download) - annotate - [select for diffs], Thu May 22 15:45:01 2008 UTC (16 years ago) by tobias
Branch: MAIN
Changes since 1.134: +2 -2 lines
Diff to previous 1.134 (colored)

expension -> expansion

ok joris, xsa (quite some time ago)

Revision 1.134 / (download) - annotate - [select for diffs], Thu Mar 13 19:54:34 2008 UTC (16 years, 2 months ago) by sthen
Branch: MAIN
Changes since 1.133: +2 -2 lines
Diff to previous 1.133 (colored)

when a file was locally removed and a diff was done against
an opencvs server (with either gnu or opencvs as the client),
no actual diff output was produced. traced to the typo fixed
in this diff.

ok joris

Revision 1.133 / (download) - annotate - [select for diffs], Sun Mar 2 19:05:34 2008 UTC (16 years, 2 months ago) by tobias
Branch: MAIN
CVS Tags: OPENBSD_4_3_BASE, OPENBSD_4_3
Changes since 1.132: +7 -3 lines
Diff to previous 1.132 (colored)

Print the right synopsis for commands on error (especially if commands
share the same function: (r)tag, etc.).

ok joris

Revision 1.132 / (download) - annotate - [select for diffs], Sat Mar 1 21:29:36 2008 UTC (16 years, 2 months ago) by deraadt
Branch: MAIN
Changes since 1.131: +4 -4 lines
Diff to previous 1.131 (colored)

spacing

Revision 1.131 / (download) - annotate - [select for diffs], Wed Feb 27 22:34:04 2008 UTC (16 years, 2 months ago) by joris
Branch: MAIN
Changes since 1.130: +22 -9 lines
Diff to previous 1.130 (colored)

prevent file races

ok tobias@

Revision 1.130 / (download) - annotate - [select for diffs], Wed Feb 27 20:04:59 2008 UTC (16 years, 2 months ago) by tobias
Branch: MAIN
Changes since 1.129: +3 -2 lines
Diff to previous 1.129 (colored)

Always end line that states diff options with a newline.

ok joris

Revision 1.129 / (download) - annotate - [select for diffs], Mon Feb 11 20:33:11 2008 UTC (16 years, 3 months ago) by tobias
Branch: MAIN
Changes since 1.128: +2 -3 lines
Diff to previous 1.128 (colored)

Cleanup buf implementation:

* Don't check for NULL on buffer creation, because it calls fatal() when
  something's wrong.
* All buffers are supposed to expand if there is no space left in them,
  so zap flags as well.
* Remove code that is now dead.

OK joris@

> Inspired by a diff from Igor Zinovik about unchecked return value.

Revision 1.128 / (download) - annotate - [select for diffs], Sat Feb 9 12:27:31 2008 UTC (16 years, 3 months ago) by tobias
Branch: MAIN
Changes since 1.127: +3 -2 lines
Diff to previous 1.127 (colored)

If run as server, (r)diff should properly write (r)diff into header
instead of "server".

OK joris@

Revision 1.127 / (download) - annotate - [select for diffs], Mon Feb 4 21:25:32 2008 UTC (16 years, 3 months ago) by tobias
Branch: MAIN
Changes since 1.126: +4 -4 lines
Diff to previous 1.126 (colored)

r* commands have their own usage; don't check usage of their working dir
equivalents.

OK joris@, xsa@

Revision 1.126 / (download) - annotate - [select for diffs], Mon Feb 4 15:07:33 2008 UTC (16 years, 3 months ago) by tobias
Branch: MAIN
Changes since 1.125: +26 -7 lines
Diff to previous 1.125 (colored)

Added -k flag support for all commands which support it.

OK joris@

Revision 1.125 / (download) - annotate - [select for diffs], Sun Feb 3 18:18:44 2008 UTC (16 years, 3 months ago) by tobias
Branch: MAIN
Changes since 1.124: +173 -40 lines
Diff to previous 1.124 (colored)

Added rdiff support.  In order to do this, some output and option fixes
had to be done for diff, too.

OK joris@

Revision 1.124 / (download) - annotate - [select for diffs], Thu Jan 31 10:15:05 2008 UTC (16 years, 3 months ago) by tobias
Branch: MAIN
Changes since 1.123: +2 -2 lines
Diff to previous 1.123 (colored)

Replaced the unused cvs_command variable cmd_req with cmd_flags, which states
if the current command is supposed to use a working directory or if it is a
repository-only command (as of now checkout -p, rtag, rlog).

Makes the code simpler, easier to read and automagically fixes some issues
we encountered with these commands (for example if a working directory
exists, or "." operations are performed).

OK joris@, niallo@

Revision 1.123 / (download) - annotate - [select for diffs], Tue Jan 29 12:00:34 2008 UTC (16 years, 3 months ago) by tobias
Branch: MAIN
Changes since 1.122: +5 -2 lines
Diff to previous 1.122 (colored)

Properly free dynamically allocated memory on error path.

> Diff from Igor Zinovik

Revision 1.122 / (download) - annotate - [select for diffs], Mon Jan 28 20:31:07 2008 UTC (16 years, 3 months ago) by tobias
Branch: MAIN
Changes since 1.121: +5 -2 lines
Diff to previous 1.121 (colored)

Properly handle -R -- although it is default, it may be overwritten mit -l
in front of it.

OK joris@, xsa@

> Diff from Igor Zinovik

Revision 1.121 / (download) - annotate - [select for diffs], Sat Sep 22 16:01:22 2007 UTC (16 years, 8 months ago) by joris
Branch: MAIN
Changes since 1.120: +21 -14 lines
Diff to previous 1.120 (colored)

better branching/sticky tag support, no branch commits yet though.

Revision 1.120 / (download) - annotate - [select for diffs], Thu Jun 28 21:38:09 2007 UTC (16 years, 10 months ago) by xsa
Branch: MAIN
CVS Tags: OPENBSD_4_2_BASE, OPENBSD_4_2
Changes since 1.119: +2 -2 lines
Diff to previous 1.119 (colored)

Sync revisions and time buffers size to be consistent with each others.
Simplifies further size tweaks if needed.
OK niallo@ ray@.

Revision 1.119 / (download) - annotate - [select for diffs], Wed Jun 27 04:23:54 2007 UTC (16 years, 10 months ago) by joris
Branch: MAIN
Changes since 1.118: +3 -3 lines
Diff to previous 1.118 (colored)

fix diff output in a remote setup so our client does not freak out.

noticed and "yes, that's much shinier" by ckuethe.

Revision 1.118 / (download) - annotate - [select for diffs], Thu Feb 22 06:42:09 2007 UTC (17 years, 2 months ago) by otto
Branch: MAIN
CVS Tags: OPENBSD_4_1_BASE, OPENBSD_4_1
Changes since 1.117: +6 -3 lines
Diff to previous 1.117 (colored)

general includes cleanup sweep. ok joris@ niallo@

Revision 1.117 / (download) - annotate - [select for diffs], Fri Feb 9 03:49:15 2007 UTC (17 years, 3 months ago) by joris
Branch: MAIN
Changes since 1.116: +2 -2 lines
Diff to previous 1.116 (colored)

remove the cvs_file_classify() `loud' argument, it was used
in the old school days and serves no purpose what so ever now.

otto@ mentioned this to me a while ago

Revision 1.116 / (download) - annotate - [select for diffs], Fri Jan 26 11:19:44 2007 UTC (17 years, 3 months ago) by joris
Branch: MAIN
Changes since 1.115: +1 -2 lines
Diff to previous 1.115 (colored)

Handle CVS/Entries and file timestamp correctly so we do
not mistakenly see a file as Modified while it is not.

As a result, we can remove the very hackish cvs_hack_time() and
GNU cvs and opencvs should almost get along now.

lotsa help and okay The otto@

Revision 1.115 / (download) - annotate - [select for diffs], Sat Jan 20 01:07:51 2007 UTC (17 years, 4 months ago) by niallo
Branch: MAIN
Changes since 1.114: +5 -3 lines
Diff to previous 1.114 (colored)

sweep opencvs for missing rcs_translate_tag() return checks.

Revision 1.114 / (download) - annotate - [select for diffs], Mon Jan 15 04:21:38 2007 UTC (17 years, 4 months ago) by joris
Branch: MAIN
Changes since 1.113: +21 -21 lines
Diff to previous 1.113 (colored)

replace old diffing mechanisms with the new fluffy RCS stuff,
okay niallo@

Revision 1.113 / (download) - annotate - [select for diffs], Sun Jan 14 23:10:56 2007 UTC (17 years, 4 months ago) by joris
Branch: MAIN
Changes since 1.112: +3 -7 lines
Diff to previous 1.112 (colored)

move things around in rcs_rev_getbuf() and rcs_rev_write_fd()
so that we do keyword expansion on-the-fly if required instead
of obtaining the revision in memory first, running over the revision
lines while expanding keywords and only then writing them to the fd
or memory buffer.

this drasticly decreases cpu usage by opencvs on very large trees (like src).

OK niallo@

Revision 1.112 / (download) - annotate - [select for diffs], Fri Jan 12 23:32:01 2007 UTC (17 years, 4 months ago) by niallo
Branch: MAIN
Changes since 1.111: +3 -3 lines
Diff to previous 1.111 (colored)

major re-work of the RCS api.  this results in 100x performance improvements in some places and much
reduced memory usage.  note that only checkout has been fully converted to use the new high-performance
functions.  other codepaths (e.g. update) still use the old method which is provided for backwards
compatibility.  we can convert the remaining slow bits over to the new api piece-by-piece.

"commit this, now" joris@
brad@ tested, too.

Revision 1.111 / (download) - annotate - [select for diffs], Thu Jan 11 10:37:18 2007 UTC (17 years, 4 months ago) by xsa
Branch: MAIN
Changes since 1.110: +19 -30 lines
Diff to previous 1.110 (colored)

strl* overload, use xasprintf().

Revision 1.110 / (download) - annotate - [select for diffs], Thu Jan 11 02:35:55 2007 UTC (17 years, 4 months ago) by joris
Branch: MAIN
Changes since 1.109: +2 -1 lines
Diff to previous 1.109 (colored)

in a remote setup:
do not connect to the remote server until we are sure all the options
passed to the commands are valid.

noticed by xsa@

Revision 1.109 / (download) - annotate - [select for diffs], Sat Jul 8 09:25:44 2006 UTC (17 years, 10 months ago) by ray
Branch: MAIN
CVS Tags: OPENBSD_4_0_BASE, OPENBSD_4_0
Changes since 1.108: +3 -3 lines
Diff to previous 1.108 (colored)

Remove file mode argument from {cvs|rcs}_buf_write_stmp().  We
always set the temporary file to mode 600, which is already done
by mkstemp().

OK joris@ and xsa@ over a month ago.

Revision 1.108 / (download) - annotate - [select for diffs], Fri Jul 7 17:37:17 2006 UTC (17 years, 10 months ago) by joris
Branch: MAIN
Changes since 1.107: +44 -3 lines
Diff to previous 1.107 (colored)

first part of opencvs remote, fairly useable on existing trees
although i advise against using it on real development trees for now.

only a few commands work right so far:
- commit
- diff
- status
- log
- update (partially working)

if you feel like testing remote and run into bugs feel free to
contact me, and please include a full trace (-t).

Revision 1.107 / (download) - annotate - [select for diffs], Sat Jul 1 01:07:50 2006 UTC (17 years, 10 months ago) by ray
Branch: MAIN
Changes since 1.106: +2 -2 lines
Diff to previous 1.106 (colored)

Indentation.

Revision 1.106 / (download) - annotate - [select for diffs], Mon Jun 19 05:05:17 2006 UTC (17 years, 11 months ago) by joris
Branch: MAIN
Changes since 1.105: +2 -3 lines
Diff to previous 1.105 (colored)

kill local and remote callback and just have one called fileproc.
we let the commands pass the correct function.

all in preparation for remote.

Revision 1.105 / (download) - annotate - [select for diffs], Fri Jun 16 20:01:10 2006 UTC (17 years, 11 months ago) by joris
Branch: MAIN
Changes since 1.104: +2 -2 lines
Diff to previous 1.104 (colored)

change a cvs_buf_load() to cvs_buf_load_fd()
spotted by xsa@ a few days ago

Revision 1.104 / (download) - annotate - [select for diffs], Fri Jun 16 14:07:42 2006 UTC (17 years, 11 months ago) by joris
Branch: MAIN
Changes since 1.103: +2 -3 lines
Diff to previous 1.103 (colored)

in preparation for the new remote code, proto.h becomes obsolete.

Revision 1.103 / (download) - annotate - [select for diffs], Wed Jun 14 20:28:53 2006 UTC (17 years, 11 months ago) by joris
Branch: MAIN
Changes since 1.102: +1 -4 lines
Diff to previous 1.102 (colored)

simplify cvs_hack_time() and the way it is called;

Revision 1.102 / (download) - annotate - [select for diffs], Thu Jun 1 20:01:47 2006 UTC (17 years, 11 months ago) by joris
Branch: MAIN
Changes since 1.101: +1 -3 lines
Diff to previous 1.101 (colored)

fix output

Revision 1.101 / (download) - annotate - [select for diffs], Wed May 31 22:24:12 2006 UTC (17 years, 11 months ago) by joris
Branch: MAIN
Changes since 1.100: +10 -1 lines
Diff to previous 1.100 (colored)

support -p flag for diff, makes dlg@ feel all warm
and fuzzie inside.

Revision 1.100 / (download) - annotate - [select for diffs], Wed May 31 07:21:25 2006 UTC (17 years, 11 months ago) by joris
Branch: MAIN
Changes since 1.99: +3 -1 lines
Diff to previous 1.99 (colored)

set diff_rev2 to file_rcsrev when we are using
the file we have on disk as the second thing to diff to.

fixes some output issues.

Revision 1.99 / (download) - annotate - [select for diffs], Tue May 30 22:25:24 2006 UTC (17 years, 11 months ago) by joris
Branch: MAIN
Changes since 1.98: +3 -2 lines
Diff to previous 1.98 (colored)

fix diff -rrevision usage

Revision 1.98 / (download) - annotate - [select for diffs], Tue May 30 21:32:52 2006 UTC (17 years, 11 months ago) by joris
Branch: MAIN
Changes since 1.97: +2 -2 lines
Diff to previous 1.97 (colored)

fill in the correct revision number we will want in file_rcsrev
for each cvs_file struct, this will help us with sticky tags,
commiting to branches and importing into existing repositories.

Revision 1.97 / (download) - annotate - [select for diffs], Mon May 29 07:17:30 2006 UTC (17 years, 11 months ago) by joris
Branch: MAIN
Changes since 1.96: +16 -11 lines
Diff to previous 1.96 (colored)

make diff accept symbols for -r too now that we have
a translation function.

Revision 1.96 / (download) - annotate - [select for diffs], Sun May 28 07:56:44 2006 UTC (17 years, 11 months ago) by joris
Branch: MAIN
Changes since 1.95: +2 -2 lines
Diff to previous 1.95 (colored)

allow commands to shut up the output from cvs_file_classify
if the commands want to output certain stuff themselfs

Revision 1.95 / (download) - annotate - [select for diffs], Sat May 27 21:11:11 2006 UTC (17 years, 11 months ago) by joris
Branch: MAIN
Changes since 1.94: +25 -14 lines
Diff to previous 1.94 (colored)

and now you can use -N to diff removed files too

Revision 1.94 / (download) - annotate - [select for diffs], Sat May 27 20:57:42 2006 UTC (17 years, 11 months ago) by joris
Branch: MAIN
Changes since 1.93: +51 -28 lines
Diff to previous 1.93 (colored)

allow diff to pick up newly added files with the -N flag.

Revision 1.93 / (download) - annotate - [select for diffs], Sat May 27 17:52:27 2006 UTC (17 years, 11 months ago) by joris
Branch: MAIN
Changes since 1.92: +5 -1 lines
Diff to previous 1.92 (colored)

dont forget to expand any keywords before diffing stuff,
otherwise we might end up with chunks that are totally wrong.

Revision 1.92 / (download) - annotate - [select for diffs], Sat May 27 15:14:27 2006 UTC (17 years, 11 months ago) by joris
Branch: MAIN
Changes since 1.91: +7 -1 lines
Diff to previous 1.91 (colored)

allow commands to respect the -l flag, if the -l flag is
specified certain commands will not recurse into directories.

at the same time introduce a method of specifying wether or not
a command should look in the repository for files.

Revision 1.91 / (download) - annotate - [select for diffs], Sat May 27 03:30:30 2006 UTC (17 years, 11 months ago) by joris
Branch: MAIN
Changes since 1.90: +119 -1677 lines
Diff to previous 1.90 (colored)

commit the new opencvs code, i have been hacking on
this for the past 2 weeks now and it should go in at
the start of the hackathon so others can help out.

this code is a lot safer, smarter, faster and best of
all it is actually doing what it is suppose to do!

basic checkout, update, status, diff and commit are
working in local mode only.
there is no support for any remote setups now.

Revision 1.90 / (download) - annotate - [select for diffs], Fri Apr 14 23:29:01 2006 UTC (18 years, 1 month ago) by joris
Branch: MAIN
Changes since 1.89: +31 -4 lines
Diff to previous 1.89 (colored)

- don't append the extension if it's already there (PR 5076).
- 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@

Revision 1.89 / (download) - annotate - [select for diffs], Fri Apr 14 02:45:35 2006 UTC (18 years, 1 month ago) by deraadt
Branch: MAIN
Changes since 1.88: +24 -24 lines
Diff to previous 1.88 (colored)

remove a metric buttload of excessive ()
no binary change; ok ray

Revision 1.88 / (download) - annotate - [select for diffs], Thu Apr 13 16:55:09 2006 UTC (18 years, 1 month ago) by ray
Branch: MAIN
Changes since 1.87: +6 -3 lines
Diff to previous 1.87 (colored)

Add error checking for vasprintf.  Stylistic suggestions from xsa@.

OK xsa@

Revision 1.87 / (download) - annotate - [select for diffs], Wed Apr 5 01:38:55 2006 UTC (18 years, 1 month ago) by ray
Branch: MAIN
Changes since 1.86: +20 -20 lines
Diff to previous 1.86 (colored)

Use variable names for sizeof, remove casts in front of xmalloc,
use xcalloc and xstrdup where appropriate, and other stuff.

OK joris@

Revision 1.86 / (download) - annotate - [select for diffs], Sat Apr 1 20:11:25 2006 UTC (18 years, 1 month ago) by joris
Branch: MAIN
Changes since 1.85: +3 -1 lines
Diff to previous 1.85 (colored)

fix some bugs that lint discovered for us.
ok niallo@

Revision 1.85 / (download) - annotate - [select for diffs], Tue Mar 28 07:17:16 2006 UTC (18 years, 1 month ago) by ray
Branch: MAIN
Changes since 1.84: +4 -4 lines
Diff to previous 1.84 (colored)

xmalloc(num * size) -> xcalloc(num, size)
asprintf -> xasprintf
Remove asprintf check, which was non-portable anyway.

``okidoki'' xsa@

Revision 1.84 / (download) - annotate - [select for diffs], Tue Mar 28 02:13:44 2006 UTC (18 years, 1 month ago) by ray
Branch: MAIN
Changes since 1.83: +9 -9 lines
Diff to previous 1.83 (colored)

Today is Integer Overflow Prevention Day:
 - Sync xmalloc.? with ssh versions.
 - Change all xrealloc() calls to new API.

``I really like this.'' niallo@

Revision 1.83 / (download) - annotate - [select for diffs], Sat Mar 25 21:29:59 2006 UTC (18 years, 1 month ago) by ray
Branch: MAIN
Changes since 1.82: +11 -13 lines
Diff to previous 1.82 (colored)

Correct integer types, remove unused arguments, non-portable bitshifts
changed to division, KNF, replace unreachable code with goto fail,
et cetera.  Found by lint.

The free() -> xfree() as well.

OK niallo@

Revision 1.82 / (download) - annotate - [select for diffs], Fri Mar 24 13:34:27 2006 UTC (18 years, 1 month ago) by ray
Branch: MAIN
Changes since 1.81: +9 -19 lines
Diff to previous 1.81 (colored)

Remove unused variables, better integer types, prevent fallthroughs.
Found by lint.

Compare char * variables against NULL for consistency and add
parentheses around complicated comparisons, suggested by xsa@.

OK xsa@

Revision 1.81 / (download) - annotate - [select for diffs], Thu Mar 23 13:09:09 2006 UTC (18 years, 2 months ago) by xsa
Branch: MAIN
Changes since 1.80: +6 -7 lines
Diff to previous 1.80 (colored)

fetch() will never return non-zero; change its return type to void.
OK niallo@.

Revision 1.80 / (download) - annotate - [select for diffs], Sun Feb 26 18:35:08 2006 UTC (18 years, 2 months ago) by niallo
Branch: MAIN
CVS Tags: OPENBSD_3_9_BASE, OPENBSD_3_9
Changes since 1.79: +4 -4 lines
Diff to previous 1.79 (colored)

remove unnecessary newline characters in cvs_log() calls.

From: Ray Lai <ray@cyth.net> in PR#5038

Revision 1.79 / (download) - annotate - [select for diffs], Mon Jan 30 17:58:47 2006 UTC (18 years, 3 months ago) by xsa
Branch: MAIN
Changes since 1.78: +2 -2 lines
Diff to previous 1.78 (colored)

strerror() -> rcs_errstr() when passing rcs_errno as argument;

Revision 1.78 / (download) - annotate - [select for diffs], Fri Jan 27 15:26:38 2006 UTC (18 years, 3 months ago) by xsa
Branch: MAIN
Changes since 1.77: +6 -9 lines
Diff to previous 1.77 (colored)

more errors handling cleanup;

Revision 1.77 / (download) - annotate - [select for diffs], Wed Jan 25 11:13:18 2006 UTC (18 years, 3 months ago) by xsa
Branch: MAIN
Changes since 1.76: +2 -9 lines
Diff to previous 1.76 (colored)

use cvs_rcs_getpath() instead of duplicating code.

Revision 1.76 / (download) - annotate - [select for diffs], Mon Jan 2 17:06:10 2006 UTC (18 years, 4 months ago) by xsa
Branch: MAIN
Changes since 1.75: +3 -2 lines
Diff to previous 1.75 (colored)

- nuke remaining err(), errx() and warnx() instances.
- make cvs_log_init() return type void.
ok joris@.

Revision 1.75 / (download) - annotate - [select for diffs], Mon Jan 2 08:11:56 2006 UTC (18 years, 4 months ago) by xsa
Branch: MAIN
Changes since 1.74: +2 -15 lines
Diff to previous 1.74 (colored)

#include's cleanup; ok joris@ niallo@.

Revision 1.74 / (download) - annotate - [select for diffs], Fri Dec 30 02:03:28 2005 UTC (18 years, 4 months ago) by joris
Branch: MAIN
Changes since 1.73: +21 -30 lines
Diff to previous 1.73 (colored)

major cleanup of the functions handling the remote cvs protocol.
makes the code a lot more readable and understandable.

ok xsa@ and niallo@

Revision 1.73 / (download) - annotate - [select for diffs], Wed Dec 21 09:09:02 2005 UTC (18 years, 5 months ago) by xsa
Branch: MAIN
Changes since 1.72: +2 -6 lines
Diff to previous 1.72 (colored)

cvs_buf_write_stmp() cannot fail anymore, missed it in previous commit;

Revision 1.72 / (download) - annotate - [select for diffs], Tue Dec 20 18:17:00 2005 UTC (18 years, 5 months ago) by xsa
Branch: MAIN
Changes since 1.71: +2 -6 lines
Diff to previous 1.71 (colored)

cvs_buf_putc() and cvs_buf_write_*() functions cannot fail anymore;

Revision 1.71 / (download) - annotate - [select for diffs], Sat Dec 10 20:27:45 2005 UTC (18 years, 5 months ago) by joris
Branch: MAIN
Changes since 1.70: +25 -83 lines
Diff to previous 1.70 (colored)

switch to xmalloc stuff, me and xsa@ agreed on this a long
time ago, but we were being held back by jfb. too bad for him.

next step is to use fatal() through out the code for unrecoverable
errors instead of trying to be all nice and fluffy and reach main() again.

ok niallo@ and xsa@

Revision 1.70 / (download) - annotate - [select for diffs], Mon Dec 5 19:53:00 2005 UTC (18 years, 5 months ago) by niallo
Branch: MAIN
Changes since 1.69: +12 -3 lines
Diff to previous 1.69 (colored)

- repair cvs diff. my date fix was too naive.

Revision 1.69 / (download) - annotate - [select for diffs], Thu Dec 1 23:02:27 2005 UTC (18 years, 5 months ago) by niallo
Branch: MAIN
Changes since 1.68: +21 -1 lines
Diff to previous 1.68 (colored)

- fix up context and unified diff output in both open rcs and open cvs so
that the date is set correctly.

ok joris@

Revision 1.68 / (download) - annotate - [select for diffs], Thu Dec 1 20:36:30 2005 UTC (18 years, 5 months ago) by niallo
Branch: MAIN
Changes since 1.67: +2 -2 lines
Diff to previous 1.67 (colored)

- fix unified and context diff output, finally!

this was a long standing bug, and the fix is hilarious.

ok joris@

Revision 1.67 / (download) - annotate - [select for diffs], Thu Nov 24 11:23:13 2005 UTC (18 years, 5 months ago) by xsa
Branch: MAIN
Changes since 1.66: +5 -3 lines
Diff to previous 1.66 (colored)

respect TMPDIR;

Revision 1.66 / (download) - annotate - [select for diffs], Mon Nov 21 15:01:10 2005 UTC (18 years, 6 months ago) by xsa
Branch: MAIN
Changes since 1.65: +2 -2 lines
Diff to previous 1.65 (colored)

- print some more informative messages
- minor knf
niallo ok

Revision 1.65 / (download) - annotate - [select for diffs], Fri Nov 18 10:30:34 2005 UTC (18 years, 6 months ago) by xsa
Branch: MAIN
Changes since 1.64: +13 -13 lines
Diff to previous 1.64 (colored)

minor knf;

Revision 1.64 / (download) - annotate - [select for diffs], Mon Nov 14 12:53:43 2005 UTC (18 years, 6 months ago) by xsa
Branch: MAIN
Changes since 1.63: +16 -16 lines
Diff to previous 1.63 (colored)

minor knf;

Revision 1.63 / (download) - annotate - [select for diffs], Sat Oct 22 17:32:57 2005 UTC (18 years, 7 months ago) by joris
Branch: MAIN
Changes since 1.62: +3 -4 lines
Diff to previous 1.62 (colored)

diff3 support, needed for merging files together;

"go for it" niallo@

Revision 1.62 / (download) - annotate - [select for diffs], Tue Oct 11 18:01:57 2005 UTC (18 years, 7 months ago) by joris
Branch: MAIN
Changes since 1.61: +4 -1 lines
Diff to previous 1.61 (colored)

close the RCSFILE on error, so we don't leak memory;

Revision 1.61 / (download) - annotate - [select for diffs], Tue Oct 11 14:27:27 2005 UTC (18 years, 7 months ago) by joris
Branch: MAIN
Changes since 1.60: +2 -2 lines
Diff to previous 1.60 (colored)

export diff_file variable so it can be set from without diff functions;
ok niallo@

Revision 1.60 / (download) - annotate - [select for diffs], Sat Oct 8 20:39:49 2005 UTC (18 years, 7 months ago) by joris
Branch: MAIN
Changes since 1.59: +2 -2 lines
Diff to previous 1.59 (colored)

add missing newline, fixes D_NORMAL diff output;
ok niallo@

Revision 1.59 / (download) - annotate - [select for diffs], Sat Oct 8 00:49:18 2005 UTC (18 years, 7 months ago) by joris
Branch: MAIN
Changes since 1.58: +6 -4 lines
Diff to previous 1.58 (colored)

KNF;

from sir reyk@

Revision 1.58 / (download) - annotate - [select for diffs], Fri Oct 7 23:59:56 2005 UTC (18 years, 7 months ago) by niallo
Branch: MAIN
Changes since 1.57: +89 -68 lines
Diff to previous 1.57 (colored)

basic `ci' support is here! more coming soon.

combined effort with joris.

ok joris@

Revision 1.57 / (download) - annotate - [select for diffs], Fri Oct 7 21:47:32 2005 UTC (18 years, 7 months ago) by reyk
Branch: MAIN
Changes since 1.56: +5 -4 lines
Diff to previous 1.56 (colored)

knf and spacing, ok joris@

Revision 1.56 / (download) - annotate - [select for diffs], Wed Oct 5 23:11:06 2005 UTC (18 years, 7 months ago) by niallo
Branch: MAIN
Changes since 1.55: +15 -37 lines
Diff to previous 1.55 (colored)

- add a diff.h header file, corresponding to public functions in diff.c
  and some #defines
- include this header in rcs.c
- link rcs against diff.c

this allows us to use the existing diff work from opencvs within functions
in the rcs.c API and thus in rcs programs. paves the way for diff support
in usr.bin/rcs programs.

ok joris@

Revision 1.55 / (download) - annotate - [select for diffs], Sun Aug 14 19:49:18 2005 UTC (18 years, 9 months ago) by xsa
Branch: MAIN
CVS Tags: OPENBSD_3_8_BASE, OPENBSD_3_8
Changes since 1.54: +6 -6 lines
Diff to previous 1.54 (colored)

missing casts; ok joris

Revision 1.54 / (download) - annotate - [select for diffs], Wed Jul 27 16:42:19 2005 UTC (18 years, 9 months ago) by xsa
Branch: MAIN
Changes since 1.53: +2 -2 lines
Diff to previous 1.53 (colored)

use LP_NOTICE instead of LP_INFO where appropriate;

Revision 1.53 / (download) - annotate - [select for diffs], Mon Jul 25 12:05:43 2005 UTC (18 years, 9 months ago) by xsa
Branch: MAIN
Changes since 1.52: +48 -47 lines
Diff to previous 1.52 (colored)

KNF;

Revision 1.52 / (download) - annotate - [select for diffs], Fri Jul 22 16:27:29 2005 UTC (18 years, 10 months ago) by joris
Branch: MAIN
Changes since 1.51: +3 -4 lines
Diff to previous 1.51 (colored)

use the cf_name field of the CVSFILE struct instead of using the old
CVS_FILE_NAME macro. This macro used to be nifty because of all
the referencing for the names, but since we don't do that anymore and
use cf_name directly... byebye CVS_FILE_NAME()

okay xsa@

Revision 1.51 / (download) - annotate - [select for diffs], Thu Jul 21 11:42:24 2005 UTC (18 years, 10 months ago) by xsa
Branch: MAIN
Changes since 1.50: +1 -2 lines
Diff to previous 1.50 (colored)

<sys/param.h> is already included in "cvs.h", no need to duplicate;

Revision 1.50 / (download) - annotate - [select for diffs], Mon Jul 11 01:32:17 2005 UTC (18 years, 10 months ago) by joris
Branch: MAIN
Changes since 1.49: +1 -4 lines
Diff to previous 1.49 (colored)



the status variable is gone.

Revision 1.49 / (download) - annotate - [select for diffs], Mon Jul 11 01:26:47 2005 UTC (18 years, 10 months ago) by niallo
Branch: MAIN
Changes since 1.48: +52 -12 lines
Diff to previous 1.48 (colored)

add proper handling for realloc() failure cases, avoiding bad idiom and
plugging a few potential memory leaks.

ok joris@

Revision 1.48 / (download) - annotate - [select for diffs], Sun Jul 10 21:50:25 2005 UTC (18 years, 10 months ago) by joris
Branch: MAIN
Changes since 1.47: +18 -20 lines
Diff to previous 1.47 (colored)



- get rid of an unused variable.
- stone() and newcand() could fail, handle it.

Revision 1.47 / (download) - annotate - [select for diffs], Sun Jul 10 13:58:19 2005 UTC (18 years, 10 months ago) by xsa
Branch: MAIN
Changes since 1.46: +1 -3 lines
Diff to previous 1.46 (colored)

no need to declare the verbosity var here as it is already done in cvs.h;

Revision 1.46 / (download) - annotate - [select for diffs], Sun Jul 10 13:53:51 2005 UTC (18 years, 10 months ago) by xsa
Branch: MAIN
Changes since 1.45: +5 -2 lines
Diff to previous 1.45 (colored)

only display info msg if -q is not specified;

Revision 1.45 / (download) - annotate - [select for diffs], Sat Jul 9 18:56:16 2005 UTC (18 years, 10 months ago) by niallo
Branch: MAIN
Changes since 1.44: +2 -2 lines
Diff to previous 1.44 (colored)

kill useless "&& r1 == NULL" expression.

ok joris@

Revision 1.44 / (download) - annotate - [select for diffs], Sat Jul 9 16:28:30 2005 UTC (18 years, 10 months ago) by niallo
Branch: MAIN
Changes since 1.43: +3 -3 lines
Diff to previous 1.43 (colored)

explicit casts to const char *

ok joris@

Revision 1.43 / (download) - annotate - [select for diffs], Tue Jun 28 08:44:44 2005 UTC (18 years, 10 months ago) by xsa
Branch: MAIN
Changes since 1.42: +8 -6 lines
Diff to previous 1.42 (colored)

- fix commands usage
- fix rdiff aliases

ok joris

Revision 1.42 / (download) - annotate - [select for diffs], Sun Jun 5 20:47:44 2005 UTC (18 years, 11 months ago) by joris
Branch: MAIN
Changes since 1.41: +42 -42 lines
Diff to previous 1.41 (colored)



* introduce cvs_putchar(), to output a single character to stdout.
  if we are in server mode send 'M' when needed.

* switch diff command to cvs_printf() and cvs_putchar() so it will
  output correctly in local and server mode.

ok xsa@, jfb@

Revision 1.41 / (download) - annotate - [select for diffs], Tue May 31 08:58:47 2005 UTC (18 years, 11 months ago) by xsa
Branch: MAIN
Changes since 1.40: +7 -7 lines
Diff to previous 1.40 (colored)

headers ordering (alphabetically) and cleanup, from mbalmer@ and myself;

Revision 1.40 / (download) - annotate - [select for diffs], Tue May 31 08:26:40 2005 UTC (18 years, 11 months ago) by xsa
Branch: MAIN
Changes since 1.39: +3 -3 lines
Diff to previous 1.39 (colored)

remove LP_ERROR log priority level and rather use LP_ERR as they are both
the same...

ok jfb joris

Revision 1.39 / (download) - annotate - [select for diffs], Tue May 31 01:59:59 2005 UTC (18 years, 11 months ago) by joris
Branch: MAIN
Changes since 1.38: +16 -1 lines
Diff to previous 1.38 (colored)



b1 and b2 can be NULL if an invalid revision is given.
if one of them is NULL, bail out.

Revision 1.38 / (download) - annotate - [select for diffs], Mon May 30 07:28:49 2005 UTC (18 years, 11 months ago) by xsa
Branch: MAIN
Changes since 1.37: +20 -13 lines
Diff to previous 1.37 (colored)

check cvs_sendarg() return value; ok joris@

Revision 1.37 / (download) - annotate - [select for diffs], Fri May 27 22:41:00 2005 UTC (18 years, 11 months ago) by joris
Branch: MAIN
Changes since 1.36: +2 -2 lines
Diff to previous 1.36 (colored)



if the user specified a revision to diff, stop caring if the file is
up to date.

Revision 1.36 / (download) - annotate - [select for diffs], Tue May 24 04:12:25 2005 UTC (19 years ago) by jfb
Branch: MAIN
Changes since 1.35: +195 -142 lines
Diff to previous 1.35 (colored)

Merge the cvs_cmd and cvs_cmd_info structures and add the necessary
fields to hook local versions of the commands.  This needs to go in
before it gets any bigger

ok joris

Revision 1.35 / (download) - annotate - [select for diffs], Sun May 22 17:48:54 2005 UTC (19 years ago) by jfb
Branch: MAIN
Changes since 1.34: +6 -28 lines
Diff to previous 1.34 (colored)

remove ununsed code

Revision 1.34 / (download) - annotate - [select for diffs], Fri May 20 20:00:53 2005 UTC (19 years ago) by joris
Branch: MAIN
Changes since 1.33: +2 -2 lines
Diff to previous 1.33 (colored)



correct wrong error code usage.

ok jfb@, xsa@

Revision 1.33 / (download) - annotate - [select for diffs], Mon Apr 25 19:09:15 2005 UTC (19 years ago) by jfb
Branch: MAIN
Changes since 1.32: +21 -2 lines
Diff to previous 1.32 (colored)

resurrect missing parts to generate rcsdiff(1)-style diffs with the -n
flag

ok xsa

Revision 1.32 / (download) - annotate - [select for diffs], Fri Apr 22 03:38:56 2005 UTC (19 years, 1 month ago) by joris
Branch: MAIN
Changes since 1.31: +4 -1 lines
Diff to previous 1.31 (colored)



missing '-R' (force recursion) option for diff.

noticed by brad@

Revision 1.31 / (download) - annotate - [select for diffs], Mon Apr 18 21:02:49 2005 UTC (19 years, 1 month ago) by jfb
Branch: MAIN
Changes since 1.30: +9 -22 lines
Diff to previous 1.30 (colored)

Modify the CVSFILE structure using a union to keep information about
both files and directories.  We can now keep the revision number for
regular files, and don't need to fetch the appropriate entry in the
command callbacks.  This saves a huge amount of parsing on Entries
files.

ok joris@

Revision 1.30 / (download) - annotate - [select for diffs], Sat Apr 16 19:05:02 2005 UTC (19 years, 1 month ago) by xsa
Branch: MAIN
Changes since 1.29: +10 -2 lines
Diff to previous 1.29 (colored)

snprintf return value check; joris ok

Revision 1.29 / (download) - annotate - [select for diffs], Thu Apr 14 16:49:09 2005 UTC (19 years, 1 month ago) by joris
Branch: MAIN
Changes since 1.28: +2 -2 lines
Diff to previous 1.28 (colored)



completely fix the diff command

Revision 1.28 / (download) - annotate - [select for diffs], Tue Apr 12 14:58:40 2005 UTC (19 years, 1 month ago) by joris
Branch: MAIN
Changes since 1.27: +13 -13 lines
Diff to previous 1.27 (colored)



introduce our own set of error codes used by the commands to report
what exactly went wrong in case of an error.

ok jfb@

Revision 1.27 / (download) - annotate - [select for diffs], Mon Apr 11 18:02:58 2005 UTC (19 years, 1 month ago) by joris
Branch: MAIN
Changes since 1.26: +1 -2 lines
Diff to previous 1.26 (colored)



don't include sysexits.h now we don't use those error codes
anymore.

Revision 1.26 / (download) - annotate - [select for diffs], Mon Apr 11 17:56:27 2005 UTC (19 years, 1 month ago) by joris
Branch: MAIN
Changes since 1.25: +3 -3 lines
Diff to previous 1.25 (colored)



remove EX_USAGE error codes

ok jfb@

Revision 1.25 / (download) - annotate - [select for diffs], Sun Apr 3 17:32:50 2005 UTC (19 years, 1 month ago) by xsa
Branch: MAIN
Changes since 1.24: +2 -2 lines
Diff to previous 1.24 (colored)

first round of EX_* exit codes removal; ok joris@.

Revision 1.24 / (download) - annotate - [select for diffs], Thu Mar 31 14:57:32 2005 UTC (19 years, 1 month ago) by joris
Branch: MAIN
Changes since 1.23: +1 -3 lines
Diff to previous 1.23 (colored)



remove unused variable.

Revision 1.23 / (download) - annotate - [select for diffs], Wed Mar 30 17:43:04 2005 UTC (19 years, 1 month ago) by joris
Branch: MAIN
Changes since 1.22: +49 -53 lines
Diff to previous 1.22 (colored)



move all the client commands to the new command framework.
eliminates a lot of duplicate code.

ok jfb@

Revision 1.22 / (download) - annotate - [select for diffs], Sun Feb 27 00:22:08 2005 UTC (19 years, 2 months ago) by jfb
Branch: MAIN
CVS Tags: OPENBSD_3_7_BASE, OPENBSD_3_7
Changes since 1.21: +2 -2 lines
Diff to previous 1.21 (colored)

Many improvements to the RCS support:

- make it possible to specify creation and the file mode
  in rcs_open()
- implicitly write the contents to disk on rcs_close() if the
  RCS handle has been changed
- fix a bug in the output of the `expand' keyword
- add functions to retrieve and modify the expansion mode
- rcs_parse() shouldn't be available to the outside
- empty string instead of `(null)' if there is no description

ok Joris

Revision 1.21 / (download) - annotate - [select for diffs], Fri Feb 25 20:32:48 2005 UTC (19 years, 2 months ago) by jfb
Branch: MAIN
Changes since 1.20: +3 -5 lines
Diff to previous 1.20 (colored)

- switch to rcsnum_parse() where appropriate
- make rcsnum_parse() fail if it encounters an invalid character

Revision 1.20 / (download) - annotate - [select for diffs], Tue Feb 1 18:03:32 2005 UTC (19 years, 3 months ago) by jfb
Branch: MAIN
Changes since 1.19: +74 -15 lines
Diff to previous 1.19 (colored)

first round of malloc()/realloc() fixes:
- avoid using the original pointer to store the return
  value of realloc(), so we can free it in case of failure
- check return values for allocation failures and return errors in
  the appropriate cases
- free the diff buffers once the diff has been generated

feedback and testing by Joris Vink

Revision 1.19 / (download) - annotate - [select for diffs], Sat Jan 29 15:47:51 2005 UTC (19 years, 3 months ago) by jfb
Branch: MAIN
Changes since 1.18: +2 -2 lines
Diff to previous 1.18 (colored)

apply sizeof() to the appropriate buffer in a strlcpy() call

spotted by Andrey Matveev (andrushock at korovino dot net)

Revision 1.18 / (download) - annotate - [select for diffs], Fri Jan 14 00:35:15 2005 UTC (19 years, 4 months ago) by jfb
Branch: MAIN
Changes since 1.17: +4 -3 lines
Diff to previous 1.17 (colored)

missing space and kill a gcc warning

Revision 1.17 / (download) - annotate - [select for diffs], Thu Jan 13 23:39:42 2005 UTC (19 years, 4 months ago) by jfb
Branch: MAIN
Changes since 1.16: +63 -7 lines
Diff to previous 1.16 (colored)

resurrect the -N and -p options to the diff command

requested and tested by brad@, thanks!

Revision 1.16 / (download) - annotate - [select for diffs], Tue Dec 28 22:07:31 2004 UTC (19 years, 4 months ago) by xsa
Branch: MAIN
Changes since 1.15: +2 -2 lines
Diff to previous 1.15 (colored)

remove signedness warnings; jfb ok

Revision 1.15 / (download) - annotate - [select for diffs], Tue Dec 28 20:39:15 2004 UTC (19 years, 4 months ago) by jfb
Branch: MAIN
Changes since 1.14: +7 -7 lines
Diff to previous 1.14 (colored)

rename parameters to avoid shadowing global declarations

Revision 1.14 / (download) - annotate - [select for diffs], Tue Dec 28 19:51:07 2004 UTC (19 years, 4 months ago) by jfb
Branch: MAIN
Changes since 1.13: +5 -5 lines
Diff to previous 1.13 (colored)

use Argument instead of Argumentx when sending a revision or date
this makes the -r and -D options work with diff

Revision 1.13 / (download) - annotate - [select for diffs], Tue Dec 14 21:40:39 2004 UTC (19 years, 5 months ago) by jfb
Branch: MAIN
Changes since 1.12: +6 -1 lines
Diff to previous 1.12 (colored)

complain about lost files

Revision 1.12 / (download) - annotate - [select for diffs], Wed Dec 8 21:11:07 2004 UTC (19 years, 5 months ago) by djm
Branch: MAIN
Changes since 1.11: +13 -4 lines
Diff to previous 1.11 (colored)

use mkstemp for local diff -r r1 -r r2; ok jfb@

Revision 1.11 / (download) - annotate - [select for diffs], Tue Dec 7 17:10:56 2004 UTC (19 years, 5 months ago) by tedu
Branch: MAIN
Changes since 1.10: +1 -8 lines
Diff to previous 1.10 (colored)

less whitespace, more pretty.  ok jfb

Revision 1.10 / (download) - annotate - [select for diffs], Mon Dec 6 21:03:12 2004 UTC (19 years, 5 months ago) by deraadt
Branch: MAIN
Changes since 1.9: +8 -15 lines
Diff to previous 1.9 (colored)

tighten vertical spacing for else; jfb ok

Revision 1.9 / (download) - annotate - [select for diffs], Mon Dec 6 02:46:47 2004 UTC (19 years, 5 months ago) by jfb
Branch: MAIN
Changes since 1.8: +3 -2 lines
Diff to previous 1.8 (colored)

Missing prototype for cvs_diff_sendflags(), removes a gcc warning

Revision 1.8 / (download) - annotate - [select for diffs], Fri Nov 26 16:23:50 2004 UTC (19 years, 5 months ago) by jfb
Branch: MAIN
Changes since 1.7: +17 -9 lines
Diff to previous 1.7 (colored)

Rewrite the internals of the file management code so that we do not keep
a full path to each file we load, and cache file names so we can have
multiple references to a single name.  This saves a lot of memory on large
trees such as /usr/src, especially on 'Makefile', 'README' and such.

Revision 1.7 / (download) - annotate - [select for diffs], Thu Aug 12 18:37:27 2004 UTC (19 years, 9 months ago) by jfb
Branch: MAIN
Changes since 1.6: +18 -8 lines
Diff to previous 1.6 (colored)

Fix handling of unknown directories

Revision 1.6 / (download) - annotate - [select for diffs], Fri Aug 6 13:08:39 2004 UTC (19 years, 9 months ago) by jfb
Branch: MAIN
Changes since 1.5: +5 -6 lines
Diff to previous 1.5 (colored)

Start using the global files list

Revision 1.5 / (download) - annotate - [select for diffs], Fri Jul 30 20:55:35 2004 UTC (19 years, 9 months ago) by jfb
Branch: MAIN
Changes since 1.4: +3 -3 lines
Diff to previous 1.4 (colored)

fix diffing by sending the base directory just before sending the 'diff'
command, and remove some debugging messages

Revision 1.4 / (download) - annotate - [select for diffs], Fri Jul 30 01:49:23 2004 UTC (19 years, 9 months ago) by jfb
Branch: MAIN
Changes since 1.3: +140 -254 lines
Diff to previous 1.3 (colored)

Move to the new API for the client-server protocol.  All functions now
take a cvs root structure as parameter.  This will allow for much easier
management of CVS trees that make use of multiple roots.

Revision 1.3 / (download) - annotate - [select for diffs], Wed Jul 14 04:32:42 2004 UTC (19 years, 10 months ago) by jfb
Branch: MAIN
Changes since 1.2: +2 -2 lines
Diff to previous 1.2 (colored)

prepare the entries interface so we can add entries

Revision 1.2 / (download) - annotate - [select for diffs], Wed Jul 14 03:59:36 2004 UTC (19 years, 10 months ago) by jfb
Branch: MAIN
Changes since 1.1: +12 -2 lines
Diff to previous 1.1 (colored)

print diffargs correctly instead of a (null).  This should make the diff
output exactly the same as the one from GNU CVS

Revision 1.1.1.1 / (download) - annotate - [select for diffs] (vendor branch), Tue Jul 13 22:02:40 2004 UTC (19 years, 10 months ago) by jfb
Branch: OpenCVS
CVS Tags: OpenCVS_0_1
Changes since 1.1: +0 -0 lines
Diff to previous 1.1 (colored)

* initial import from the cvs-tools module

Revision 1.1 / (download) - annotate - [select for diffs], Tue Jul 13 22:02:40 2004 UTC (19 years, 10 months ago) by jfb
Branch: MAIN
Branch point for: OpenCVS

Initial revision

This form allows you to request diff's between any two revisions of a file. You may select a symbolic revision name using the selection box or you may type in a numeric name using the type-in text box.