bug-cvs
[Top][All Lists]
Advanced

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

Re: cvs has problems using LockDir when CVSROOT holds a symlink


From: Derek Robert Price
Subject: Re: cvs has problems using LockDir when CVSROOT holds a symlink
Date: Wed, 24 Sep 2003 02:09:22 -0400
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

Mark D. Baushke wrote:

| For 1.12.x, it might be reasonable to use the GNULIB version of
|
|canonicalize_file_name() by adding a lib/canonicalize.c file that gets
|built if the function does not exist on the target platform.


Is there a GNULIB version?  I just looked and I do not see a
canonicalize.c.  If you meant to create a CVS lib version, I think I
would prefer a name like canonicalize_path.c or the like.

I did just notice an interesting module in GNULIB named "same" that uses
stat to compare two paths and verify that they point to the same inode,
but that could be overkill in this case.  We couldn't use the "same"
module directly regardless since it requires that the last component of
the path (determined via basename) be the same string for some reason
rather than using the inode there too.

Also, my comments on issue #33 will be two years old on Friday.  That
was long before I rewrote the code to handle symlinks and I ended up
doing _that_ by rewriting do_recursion to keep track of recursing into
directories for the r* commands rather than relying on xgetwd like I had
in mind two years ago.  This sounds like a bug in that code, if it even
exists at all anymore in 1.12.x.  You didn't mention which version you
found this problem in.  As for 1.11.x, symlinks are pretty darn broke
and I wouldn't bother fixing one single bug there anyhow.  I had to
overhaul quite a bit of code to get symlinks to work, which is why I
only checked the fix into 1.12.x.

Sorry I misled you.  If you will confirm that this bug isn't in the
1.12.x tree, I will close issue #33.

I'm not sure whether it would be useful to commit your test case.  I
hacked cvsroot at the beginning of sanity.sh to be a symlink and ran the
entire suite when I first made symlinks work in 1.12.x and am making
every test run with a symlinked root in addition to a standard one as
part of the new autotest suite.

Going through the ChangeLog, I also just noticed that I have already
added an "xresolvepath" function to src/filesubr.c and the other
locations.  It would probably be reasonable to move xresolvepath to
lib/xresolvepath.c and use save_cwd and restore_cwd rather than
reinventing the wheel like I appear to have in "xresolvepath".

Derek

- --
~                *8^)

Email: address@hidden

Get CVS support at <http://ximbiot.com>!
- --
You seem... to consider the judges as the ultimate arbiters of all
constitutional questions; a very dangerous doctrine indeed, and one
which would place us under the despotism of an oligarchy....  The
Constitution has erected no such single tribunal.

           - Thomas Jefferson, 1820
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.0.7 (GNU/Linux)
Comment: Using GnuPG with Netscape - http://enigmail.mozdev.org

iD8DBQE/cTURLD1OTBfyMaQRAqlgAKCrdPRJuBuaWYjvfG3QB/mdhn2ovwCdHFOb
f879E/DzxtW+WWVZSiYd9r4=
=q1Ky
-----END PGP SIGNATURE-----






reply via email to

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