[Libreoffice-commits] core.git: Branch 'libreoffice-5-1' - svtools/source ucb/source
Giuseppe Castagno
giuseppe.castagno at acca-esse.eu
Thu Jan 7 05:28:59 PST 2016
svtools/source/control/breadcrumb.cxx | 11 ++++++++++-
ucb/source/ucp/webdav-neon/NeonSession.cxx | 1 +
2 files changed, 11 insertions(+), 1 deletion(-)
New commits:
commit 8369e7d511d5cc07b8fac31a05a5897f58b46740
Author: Giuseppe Castagno <giuseppe.castagno at acca-esse.eu>
Date: Sat Jan 2 16:03:20 2016 +0100
Related tdf#96833: breadcrumb: setting URL, host port gets lost.
At the same time added a log in WebDAV, useful to discover the
issue.
Change-Id: I3435f8d3da28f7d6b4c2e154cf2bb5ee33a9a690
Reviewed-on: https://gerrit.libreoffice.org/21047
Tested-by: Jenkins <ci at libreoffice.org>
Reviewed-by: Stephan Bergmann <sbergman at redhat.com>
(cherry picked from commit 5c4de8f1991f1a9964e661717dc6b46f6a6a3608)
Reviewed-on: https://gerrit.libreoffice.org/21172
Reviewed-by: Giuseppe Castagno <giuseppe.castagno at acca-esse.eu>
Reviewed-by: Katarina Behrens <Katarina.Behrens at cib.de>
diff --git a/svtools/source/control/breadcrumb.cxx b/svtools/source/control/breadcrumb.cxx
index 2f7766e..b611a42 100644
--- a/svtools/source/control/breadcrumb.cxx
+++ b/svtools/source/control/breadcrumb.cxx
@@ -105,13 +105,22 @@ void Breadcrumb::SetURL( const OUString& rURL )
m_aCurrentURL = rURL;
INetURLObject aURL( rURL );
aURL.setFinalSlash();
+ //prepare the Host port
+ OUString sHostPort;
+
+ if( aURL.HasPort() )
+ {
+ sHostPort += ":";
+ sHostPort += sHostPort.number( aURL.GetPort() );
+ }
OUString sUser = aURL.GetUser( INetURLObject::NO_DECODE );
OUString sPath = aURL.GetURLPath(INetURLObject::DECODE_WITH_CHARSET);
OUString sRootPath = INetURLObject::GetScheme( aURL.GetProtocol() )
+ sUser
+ ( sUser.isEmpty() ? OUString() : "@" )
- + aURL.GetHost();
+ + aURL.GetHost()
+ + sHostPort;
int nSegments = aURL.getSegmentCount();
unsigned int nPos = 0;
diff --git a/ucb/source/ucp/webdav-neon/NeonSession.cxx b/ucb/source/ucp/webdav-neon/NeonSession.cxx
index 2c3c60c..5bce365 100644
--- a/ucb/source/ucp/webdav-neon/NeonSession.cxx
+++ b/ucb/source/ucp/webdav-neon/NeonSession.cxx
@@ -1746,6 +1746,7 @@ void NeonSession::HandleError( int nError,
m_aProxyName, m_nProxyPort ) );
case NE_CONNECT: // Could not connect to server
+ SAL_WARN( "ucb.ucp.webdav", "DAVException::DAV_HTTP_CONNECT" );
throw DAVException( DAVException::DAV_HTTP_CONNECT,
NeonUri::makeConnectionEndPointString(
m_aHostName, m_nPort ) );
More information about the Libreoffice-commits
mailing list