bin/117831: csup is incompatible WRT handling unknown RCS keywords

YONETANI Tomokazu qhwt+fbsd at les.ath.cx
Sun Nov 4 20:30:02 PST 2007


>Number:         117831
>Category:       bin
>Synopsis:       csup is incompatible WRT handling unknown RCS keywords
>Confidential:   no
>Severity:       serious
>Priority:       high
>Responsible:    freebsd-bugs
>State:          open
>Quarter:        
>Keywords:       
>Date-Required:
>Class:          sw-bug
>Submitter-Id:   current-users
>Arrival-Date:   Mon Nov 05 04:30:02 UTC 2007
>Closed-Date:
>Last-Modified:
>Originator:     YONETANI Tomokazu
>Release:        
>Organization:
>Environment:
>Description:
csup is a cvsup client program written in C and is supposed to be a drop-in replacement when used in CHECKOUT mode.  However, when it comes to checking out from a CVS repository containing commits made by cvs-1.12.
CVS developers decided to introduce a new RCS keyword(`newphrase' as in rcsfile(5)), `commitid', to assign a unique session string to files committed at the same time, sometime during cvs-1.12.  Prior cvs versions display a warning
saying that it doesn't know about the `commitid' keyword, but they otherwise work without a problem.
The cvsup server code running on cvsup servers around the world currently doesn't know about this commitid keyword, either.  When it encounters an unknown RCS keyword, either in CVS mode or CHECKOUT mode, it appends a special data to the delta command('D'), as described starting from the line 434 of doc/Protocol file in cvsup distribution (yes, that part is in the middle of 'V' command, which only applies to CVS mode, and the CHECKOUT mode counterpart is 'U' command, which begins at line 398, but it states
      D <revNum> <diffBase> <revDate> <author>
        Add a delta.  See the description under the "V" command.
so 'N' also applies to CHECKOUT mode.

The cvsup client code operating in CHECKOUT mode does not perform any operation when it sees this 'N'(or 'n'), so it has no problem updating from a CVS repository containing `commitid' keywords.
csup, on the other hand, only supports 'L', 'S', or 'T' for 'D' command, and it aborts operation.  So you can checkout from a CVS repository created with cvs-1.12.x, but you can't update your work directory after someone has committed to it using cvs-1.12.x.
>How-To-Repeat:
you may not see the symptom unless the delta contains newphrase, so it probably does not stop at the first checkout.
1. set up a cvsup collection; you can use either cvs-1.11 or cvs-1.12 to create the CVS repository
2. checkout the repository using csup
3. commit something to the repository using cvs-1.12
4. update the work directory using csup again
>Fix:
There could be a few fixes to this problem
  (easiest-but-probably-less correct one first):

1. Document that csup doesn't (won't?) support any CVS repositories unknown to cvsup servers.
2. Apply a patch like this to csup
  http://les.ath.cx/FreeBSD/csup-commitid.diff

3. Convince either or both authors of cvsup and csup to officially support commitid keyword; I can't do this by myself as I received no response from any of them for more than a year.

>Release-Note:
>Audit-Trail:
>Unformatted:


More information about the freebsd-bugs mailing list