Alan,
Thanks for the good research went into the root cause and a workaround, but
should we consider fixing APR instead of adding the workaround to the APR
client (ie: Subversion)?
Your research clearly shows that APR is producing different results on
different platforms, which is contradictory to its stated goal of being the
"portable runtime".
thanks in advance for your consideration,
Paul
-----Original Message-----
From: Alan Wood [mailto:alan.wood_at_clear.net.nz]
Sent: Tuesday, October 07, 2008 2:26 AM
To: dev_at_subversion.tigris.org
Cc: Bert Huijben; Jason Wenger
Subject: [PATCH] Fix for renaming errors on Samba working copies.
Hi All
I am continuing to look into using subversion working copies on Samba
shares. Here is a patch to allow the renaming of read-only files.
There are other work arounds to this such as changing the Samba
configuration file to include "force create mode 0200" which stops the files
being read-only and also "delete readonly = yes", but these do not cover the
case where the working copy is being used from both the Samba share and the
Linux side.
The "delete readonly = yes" does not appear to effect renames.
This patch checks the error return from the apr_file_rename() and if the
code was access_denied then if resets the read-only flag and tries again. I
have made no attempt to put the read-only flag back. Note that if we set the
read-only flag again that it will only reset the u+w bit not the g+w if that
was set. But sharing working copies within a group sounds bad to me anyway.
The test that was failing was:
Using TortoiseSVN:
mkdir test
svn ps blah blah test
svn commit -m "this will fail"
The result:
Error: Commit succeeded, but other errors follow:
Error: Error bumping revisions post-commit (details follow):
Error: In directory 'H:\test\test'
Error: Error processing command 'committed' in 'H:\test\test'
Error: Can't move 'H:\test\test\.svn\dir-props' to
'H:\test\test\.svn\dir-prop-base':
Error: Access is denied.
This is repeatable and also shows up on Linux-Linux Samba shares though in
that case the Samba client code should really be fixed.
If someone wants to try this without the WIN32 conditionals then go for it.
Alan
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe_at_subversion.tigris.org
For additional commands, e-mail: dev-help_at_subversion.tigris.org
Received on 2008-10-07 15:49:45 CEST