Caldav: workaround for Lightning bug, return 403 instead of 503 on server unavailable

git-svn-id: http://svn.code.sf.net/p/davmail/code/trunk@2091 3d1905a2-6b24-0410-a738-b14d5a86fcbd
This commit is contained in:
mguessan 2013-04-23 08:29:15 +00:00
parent 6a75d051eb
commit f9715c60c4
1 changed files with 2 additions and 2 deletions

View File

@ -172,7 +172,7 @@ public class CaldavConnection extends AbstractConnection {
} catch (DavMailAuthenticationException e) { } catch (DavMailAuthenticationException e) {
if (Settings.getBooleanProperty("davmail.enableKerberos")) { if (Settings.getBooleanProperty("davmail.enableKerberos")) {
// authentication failed in Kerberos mode => not available // authentication failed in Kerberos mode => not available
sendErr(HttpStatus.SC_SERVICE_UNAVAILABLE, "Kerberos authentication failed"); sendErr(HttpStatus.SC_FORBIDDEN, "Kerberos authentication failed");
} else { } else {
sendUnauthorized(); sendUnauthorized();
} }
@ -1121,7 +1121,7 @@ public class CaldavConnection extends AbstractConnection {
} else if (e instanceof HttpPreconditionFailedException) { } else if (e instanceof HttpPreconditionFailedException) {
sendErr(HttpStatus.SC_PRECONDITION_FAILED, message); sendErr(HttpStatus.SC_PRECONDITION_FAILED, message);
} else { } else {
sendErr(HttpStatus.SC_SERVICE_UNAVAILABLE, message); sendErr(HttpStatus.SC_FORBIDDEN, message);
} }
} }