From: Joe Orton Date: Mon, 7 Jun 2004 10:41:01 +0000 (+0000) Subject: Backport from HEAD: X-Git-Tag: 2.0.50~37 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=e81854d95c2c1c1c5d6e5839f8006ba7dc8e4cfd;p=thirdparty%2Fapache%2Fhttpd.git Backport from HEAD: * modules/dav/fs/repos.c (dav_fs_create_collection): Give a 409 rather than a 403 if apr_dir_make fails with ENOENT. * modules/dav/main/mod_dav.c (dav_method_put): Fix segfault in auto-versioning error handling path. PR: 29034, 29148 Reviewed by: Jeff Trawick, Andr�� Malo git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/branches/APACHE_2_0_BRANCH@103869 13f79535-47bb-0310-9956-ffa450edef68 --- diff --git a/CHANGES b/CHANGES index 12de40922c5..751e3bffde8 100644 --- a/CHANGES +++ b/CHANGES @@ -5,6 +5,10 @@ Changes with Apache 2.0.50 (trusted) client certificate subject DN which exceeds 6K in length. [Joe Orton] + *) mod_dav_fs: Fix MKCOL response for missing parent collections, which + caused issues for the Eclipse WebDAV extension. + PR 29034. [Joe Orton] + *) mod_deflate: Fix memory consumption (which was proportional to the response size). PR 29318. [Joe Orton] diff --git a/STATUS b/STATUS index 5676354241e..f443b3f8a1d 100644 --- a/STATUS +++ b/STATUS @@ -1,5 +1,5 @@ APACHE 2.0 STATUS: -*-text-*- -Last modified at [$Date: 2004/06/07 10:31:51 $] +Last modified at [$Date: 2004/06/07 10:41:00 $] Release: @@ -204,17 +204,6 @@ PATCHES TO BACKPORT FROM 2.1 http://cvs.apache.org/viewcvs.cgi/httpd-2.0/modules/aaa/mod_auth_digest.c?r1=1.86&r2=1.87 +1: geoff, nd - *) mod_dav: Fix a segfault in an autoversioning error path. - http://cvs.apache.org/viewcvs.cgi/httpd-2.0/modules/dav/main/mod_dav.c?r1=1.106&r2=1.107 - PR: 29148 - +1: jorton, trawick, nd - - *) mod_dav: Fix a 2518 compliance issue which affects Eclipse; give a 409 - rather than a 403 for a MKCOL with a missing intermediate collection - http://cvs.apache.org/viewcvs.cgi/httpd-2.0/modules/dav/fs/repos.c?r1=1.80&r2=1.81 - PR: 29034 - +1: jorton, trawick, nd - *) mod_dav: Send an EOS at the end of the multistatus brigade. http://cvs.apache.org/viewcvs.cgi/httpd-2.0/modules/dav/main/mod_dav.c?r1=1.105&r2=1.106 +1: jorton diff --git a/modules/dav/fs/repos.c b/modules/dav/fs/repos.c index 10ae547a9ec..f3c61230626 100644 --- a/modules/dav/fs/repos.c +++ b/modules/dav/fs/repos.c @@ -987,6 +987,11 @@ static dav_error * dav_fs_create_collection(dav_resource *resource) "There is not enough storage to create " "this collection."); } + else if (APR_STATUS_IS_ENOENT(status)) { + return dav_new_error(ctx->pool, HTTP_CONFLICT, 0, + "Cannot create collection; intermediate " + "collection does not exist."); + } else if (status != APR_SUCCESS) { /* ### refine this error message? */ return dav_new_error(ctx->pool, HTTP_FORBIDDEN, 0, diff --git a/modules/dav/main/mod_dav.c b/modules/dav/main/mod_dav.c index dbc163ebfbf..49cdef79dc3 100644 --- a/modules/dav/main/mod_dav.c +++ b/modules/dav/main/mod_dav.c @@ -1019,7 +1019,7 @@ static int dav_method_put(request_rec *r) if (err2 != NULL) { /* just log a warning */ - err2 = dav_push_error(r->pool, err->status, 0, + err2 = dav_push_error(r->pool, err2->status, 0, "The PUT was successful, but there " "was a problem automatically checking in " "the resource or its parent collection.",