You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@subversion.apache.org by sv...@apache.org on 2013/06/24 06:00:43 UTC
svn commit: r1495919 - in /subversion/branches/1.8.x: ./ STATUS
subversion/mod_dav_svn/version.c
Author: svn-role
Date: Mon Jun 24 04:00:43 2013
New Revision: 1495919
URL: http://svn.apache.org/r1495919
Log:
Merge r1490684 from trunk:
* r1490684
Return 500 rather than 409 when commit fails and it is not a conflict.
Justification:
Not a client failure so 4xx is wrong.
Votes:
+1: philip, rhuijben, stefan2
Modified:
subversion/branches/1.8.x/ (props changed)
subversion/branches/1.8.x/STATUS
subversion/branches/1.8.x/subversion/mod_dav_svn/version.c
Propchange: subversion/branches/1.8.x/
------------------------------------------------------------------------------
Merged /subversion/trunk:r1490684
Modified: subversion/branches/1.8.x/STATUS
URL: http://svn.apache.org/viewvc/subversion/branches/1.8.x/STATUS?rev=1495919&r1=1495918&r2=1495919&view=diff
==============================================================================
--- subversion/branches/1.8.x/STATUS (original)
+++ subversion/branches/1.8.x/STATUS Mon Jun 24 04:00:43 2013
@@ -175,13 +175,6 @@ Veto-blocked changes:
Approved changes:
=================
- * r1490684
- Return 500 rather than 409 when commit fails and it is not a conflict.
- Justification:
- Not a client failure so 4xx is wrong.
- Votes:
- +1: philip, rhuijben, stefan2
-
* r1491707
Add version header to svnpubsub server.
Justification:
Modified: subversion/branches/1.8.x/subversion/mod_dav_svn/version.c
URL: http://svn.apache.org/viewvc/subversion/branches/1.8.x/subversion/mod_dav_svn/version.c?rev=1495919&r1=1495918&r2=1495919&view=diff
==============================================================================
--- subversion/branches/1.8.x/subversion/mod_dav_svn/version.c (original)
+++ subversion/branches/1.8.x/subversion/mod_dav_svn/version.c Mon Jun 24 04:00:43 2013
@@ -1033,8 +1033,11 @@ dav_svn__checkin(dav_resource *resource,
if (serr)
{
+ int status;
+
if (serr->apr_err == SVN_ERR_FS_CONFLICT)
{
+ status = HTTP_CONFLICT;
msg = apr_psprintf(resource->pool,
"A conflict occurred during the CHECKIN "
"processing. The problem occurred with "
@@ -1042,10 +1045,12 @@ dav_svn__checkin(dav_resource *resource,
conflict_msg);
}
else
- msg = "An error occurred while committing the transaction.";
+ {
+ status = HTTP_INTERNAL_SERVER_ERROR;
+ msg = "An error occurred while committing the transaction.";
+ }
- return dav_svn__convert_err(serr, HTTP_CONFLICT, msg,
- resource->pool);
+ return dav_svn__convert_err(serr, status, msg, resource->pool);
}
else
{
@@ -1540,8 +1545,11 @@ merge(dav_resource *target,
if (serr)
{
const char *msg;
+ int status;
+
if (serr->apr_err == SVN_ERR_FS_CONFLICT)
{
+ status = HTTP_CONFLICT;
/* ### we need to convert the conflict path into a URI */
msg = apr_psprintf(pool,
"A conflict occurred during the MERGE "
@@ -1550,9 +1558,12 @@ merge(dav_resource *target,
conflict);
}
else
- msg = "An error occurred while committing the transaction.";
+ {
+ status = HTTP_INTERNAL_SERVER_ERROR;
+ msg = "An error occurred while committing the transaction.";
+ }
- return dav_svn__convert_err(serr, HTTP_CONFLICT, msg, pool);
+ return dav_svn__convert_err(serr, status, msg, pool);
}
else
{