From b95a5db5cbe276a331264f45d7d0c1efc9eb8dcf Mon Sep 17 00:00:00 2001 From: Greg Stein Date: Wed, 24 Jul 2013 21:09:38 +0000 Subject: [PATCH] Fix bug #55304 with the provided patch, slightly reformatted. In short: do not validate conditions of a COPY source's parent since it is not modified during the operation. * modules/dav/main/mod_dav.c: (dav_method_copymove): adjust params to dav_validate_request() git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@1506714 13f79535-47bb-0310-9956-ffa450edef68 --- modules/dav/main/mod_dav.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/modules/dav/main/mod_dav.c b/modules/dav/main/mod_dav.c index 2e040a7190..ae5291a86d 100644 --- a/modules/dav/main/mod_dav.c +++ b/modules/dav/main/mod_dav.c @@ -2763,7 +2763,7 @@ static int dav_method_copymove(request_rec *r, int is_move) * The multistatus responses will contain the information about any * resource that fails the validation. * - * We check the parent resource, too, since this is a MOVE. Moving the + * We check the parent resource, too, if this is a MOVE. Moving the * resource effectively removes it from the parent collection, so we * must ensure that we have met the appropriate conditions. * @@ -2772,7 +2772,8 @@ static int dav_method_copymove(request_rec *r, int is_move) */ if ((err = dav_validate_request(r, resource, depth, NULL, &multi_response, - DAV_VALIDATE_PARENT + (is_move ? DAV_VALIDATE_PARENT + : DAV_VALIDATE_RESOURCE) | DAV_VALIDATE_USE_424, NULL)) != NULL) { err = dav_push_error(r->pool, err->status, 0, -- 2.40.0