bug-cvs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: update: patch: relative path bugs in cvs (client/server mode only)


From: Derek Robert Price
Subject: Re: update: patch: relative path bugs in cvs (client/server mode only)
Date: Thu, 01 Apr 2004 17:21:32 -0500
User-agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.4) Gecko/20030624 Netscape/7.1

-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Chris Bohn wrote:

> regenerated against the head, attached to issue 81, and pasted below
> (additionally, I fixed a hard-coded path in sanity.sh to be
> ${CVSROOT_DIRNAME}):


Doesn't look like it.  You may have hardcoded your own path and then
fixed that.

> NEWS entry:
> * using relative paths now works under client/server mode


Thanks.

> Log entry:
> 2004-03-30        Chris Bohn  <address@hidden>
>
>   * client.c, client.h (send_files, send_file_names, send_max_dotdot):
>   I pulled out the code for calculating and sending max-dotdot to the
>   server into a new function that is now called from both send_files
>   and send_file_names.  Max-dotdot was previously only sent from
>   send_file_names.  That was fine because send_file_names was called
>   before send_files for a while, but when multiple repository support
>   was added, the send_files and send_file_names calls were swapped, which
>   led to Max-dotdot not getting sent at the right time.  That led to
>   relative path operations typically failing.  This change leaves
>   send_file_names sending Max-dotdot and adds it being sent with
> send_files.
>   This fixes the relative path problems described in issue 81.  It may
> be ok
>   to remove sending Max-dotdot from send_file_names, but since I'm
> sure all
>   possible variations likely aren't covered by the regression tests, I
> thought
>   it would be safer to leave it, and it causes no harm (other than a
> little
>   extra traffic).


This is a bit more verbose than really necessary for a ChangeLog.
Please be more abstract in future ChangeLogs.  Describe fixes in more
detail in the emails containing the patch, in the issue, or in the
comments in the code when appropriate.

I took out the call in send_file_names.  It is probably unecessary.  The
test suite tests a lot of cases, and if we couldn't find a broken one
yet, then I am content to wait for the bug report so we can fix it and
add a test.

Your patch was extremely mangled, with tabs converted to spaces and who
knows what else.  I read it and reimplemented it, mostly.

> [D:\temp\ccvs\src]cvs diff -u client.h
> Index: client.h
> ===================================================================
> RCS file: /cvs/ccvs/src/client.h,v
> retrieving revision 1.48
> diff -u -r1.48 client.h
> --- client.h    22 Mar 2004 15:37:34 -0000      1.48
> +++ client.h    1 Apr 2004 18:30:02 -0000
> @@ -83,6 +83,10 @@
>  void
>  start_server (void);
>
> +/* Calculate and send max-dotdot to the server */
> +void
> +send_max_dotdot(int argc, char **argv);
> +
>  /* Send the names of all the argument files to the server.  */
>  void
>  send_file_names (int argc, char **argv, unsigned int flags);


I removed this prototype - this function is only called from within
client.c and doesn't need to export a prototype.

Other than that, I think you got it right.  I'm running it through make
check on the stable branch now.

Thanks for the submission,

Derek

- --
                *8^)

Email: address@hidden

Get CVS support at <http://ximbiot.com>!
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.2.1 (GNU/Linux)
Comment: Using GnuPG with Netscape - http://enigmail.mozdev.org

iD8DBQFAbJXrLD1OTBfyMaQRAly/AKDuPiiXwmwY4OXeCR6beomEBm8cAwCgr8Gd
tTCuM954XHufFpVSg0OAZg8=
=0Efy
-----END PGP SIGNATURE-----






reply via email to

[Prev in Thread] Current Thread [Next in Thread]