From 6dcd231892d80d2f130d1b9ebb9cf7dfa1115df1 Mon Sep 17 00:00:00 2001 From: Giuseppe Castagno Date: Sat, 23 Jul 2016 12:55:20 +0200 Subject: [PATCH] tdf#101094 (6) OPTIONS: Do not retry on HTTP error 501 HTTP error 501 the server tells us the used method is not implemented, non need to retry. Change-Id: I4529d2bc27a87e8f3463ded578c6c55e0701ae17 Reviewed-on: https://gerrit.libreoffice.org/27636 Tested-by: Jenkins Reviewed-by: Giuseppe Castagno --- ucb/source/ucp/webdav-neon/DAVResourceAccess.cxx | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/ucb/source/ucp/webdav-neon/DAVResourceAccess.cxx b/ucb/source/ucp/webdav-neon/DAVResourceAccess.cxx index e1ff5d6d82cf..51feef68cf7b 100644 --- a/ucb/source/ucp/webdav-neon/DAVResourceAccess.cxx +++ b/ucb/source/ucp/webdav-neon/DAVResourceAccess.cxx @@ -1197,7 +1197,11 @@ bool DAVResourceAccess::handleException( const DAVException & e, int errorCount // if we have a bad connection try again. Up to three times. case DAVException::DAV_HTTP_ERROR: // retry up to three times, if not a client-side error. + // exception: error 501, server side error that + // tells us the used method is not implemented + // on the server, it's nonsense to insist... if ( ( e.getStatus() < 400 || e.getStatus() >= 500 ) && + ( e.getStatus() != 501 ) && errorCount < 3 ) { return true;