[svn.haxx.se] · SVN Dev · SVN Users · SVN Org · TSVN Dev · TSVN Users · Subclipse Dev · Subclipse Users · this month's index

Should mod_dav_svn turn SVN_ERR_FS_LOCK_OWNER_MISMATCH into HTTP_LOCKED?

From: Philip Martin <philip.martin_at_wandisco.com>
Date: Thu, 28 Apr 2011 14:01:53 +0100

If I lock a file in a wc using one user ID and then commit that wc using
a different user ID the commit fails, which is the expected behaviour.
Over HTTP I get "500 internal server error" which is not a good error
for something that is a client problem.

We could use "423 locked" instead, would that be sensible from a DAV
point of view?

Index: subversion/mod_dav_svn/util.c
===================================================================
--- subversion/mod_dav_svn/util.c (revision 1097437)
+++ subversion/mod_dav_svn/util.c (working copy)
@@ -130,6 +130,7 @@
       case SVN_ERR_UNSUPPORTED_FEATURE:
         status = HTTP_NOT_IMPLEMENTED;
         break;
+ case SVN_ERR_FS_LOCK_OWNER_MISMATCH:
       case SVN_ERR_FS_PATH_ALREADY_LOCKED:
         status = HTTP_LOCKED;
         break;

-- 
Philip
Received on 2011-04-28 15:02:29 CEST

This is an archived mail posted to the Subversion Dev mailing list.

This site is subject to the Apache Privacy Policy and the Apache Public Forum Archive Policy.