summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorGiuseppe Castagno <giuseppe.castagno@acca-esse.eu>2015-11-21 20:41:06 +0100
committerMichael Stahl <michael.stahl@allotropia.de>2021-11-01 18:28:31 +0100
commit6c0c0ce22e8b9085ed0993a2445560206b05724e (patch)
treefbe4eacf4211e4bac947f11bb0ae0842835db63b
parent11a457538a300d8df0c5c03d3cb590e94e6d99fa (diff)
ucb: webdav-curl: Related tdf#90700 Add configuration for web connection timeout.
Currently the connection timeout is governed by operating system default. LO timeouts will be used in place of the TCP socket operating system ones, only in operating system where this is currently possible. The timeouts to use can be changed in LO configuration: 'Tools > Options > Advanced > Expert Configuration'. Propriety names are ConnectTimeout and ReadTimeout. ConnectTimeout contains the timeout (in seconds) used when making a connection (max 180 s, min 2 s, default 20 s). ReadTimeout contains the timeout (in seconds) used when reading from a socket (max 180 s, min 20 s, default 60 s). [ port of commit 14220052ef2b8675ee12aad63b0402f023d9760a omitting Session change which isn't directly possible ] Change-Id: I276851958f587346a36ee5f173b3e4fb88a944b3 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/123276 Tested-by: Michael Stahl <michael.stahl@allotropia.de> Reviewed-by: Michael Stahl <michael.stahl@allotropia.de>
-rw-r--r--ucb/source/ucp/webdav-curl/webdavcontent.cxx6
1 files changed, 2 insertions, 4 deletions
diff --git a/ucb/source/ucp/webdav-curl/webdavcontent.cxx b/ucb/source/ucp/webdav-curl/webdavcontent.cxx
index e2ed80e3c5ed..f06169f323ba 100644
--- a/ucb/source/ucp/webdav-curl/webdavcontent.cxx
+++ b/ucb/source/ucp/webdav-curl/webdavcontent.cxx
@@ -3303,6 +3303,7 @@ uno::Any Content::MapDAVException( const DAVException & e, bool bWrite )
// case DAVException::DAV_HTTP_AUTHPROXY:
// break;
+ case DAVException::DAV_HTTP_TIMEOUT:
case DAVException::DAV_HTTP_CONNECT:
aException <<=
ucb::InteractiveNetworkConnectException(
@@ -3313,10 +3314,6 @@ uno::Any Content::MapDAVException( const DAVException & e, bool bWrite )
break;
// @@@ No matching InteractiveNetwork*Exception
-// case DAVException::DAV_HTTP_TIMEOUT:
-// break;
-
-// @@@ No matching InteractiveNetwork*Exception
// case DAVException::DAV_HTTP_REDIRECT:
// break;
@@ -3405,6 +3402,7 @@ uno::Any Content::MapDAVException( const DAVException & e, bool bWrite )
bool Content::shouldAccessNetworkAfterException( const DAVException & e )
{
if ( ( e.getStatus() == SC_NOT_FOUND ) ||
+ ( e.getError() == DAVException::DAV_HTTP_TIMEOUT ) ||
( e.getError() == DAVException::DAV_HTTP_LOOKUP ) ||
( e.getError() == DAVException::DAV_HTTP_CONNECT ) ||
( e.getError() == DAVException::DAV_HTTP_AUTH ) ||