diff options
author | Vasily Melenchuk <vasily.melenchuk@cib.de> | 2015-01-27 16:18:24 +0000 |
---|---|---|
committer | Stephan Bergmann <sbergman@redhat.com> | 2015-02-02 10:57:37 +0100 |
commit | 0706b5756e06b7773a78e3046a47efc2c81d92b1 (patch) | |
tree | 20f29c5e5c4cd4d12af870994312cf38f98b1736 /sw | |
parent | 87a5cf7db1f070cbc4a674a1c12c805a2c950856 (diff) |
tdf#76291 write encoded URL as href in html output
INetURLObject class is used to create correctly encoded URL
Change-Id: Icc9e71e848fd8a0b487f74232b9ad3e7ddde50b4
Signed-off-by: Stephan Bergmann <sbergman@redhat.com>
Diffstat (limited to 'sw')
-rw-r--r-- | sw/source/filter/html/wrthtml.cxx | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/sw/source/filter/html/wrthtml.cxx b/sw/source/filter/html/wrthtml.cxx index 64c85075e673..eaa8831ba28d 100644 --- a/sw/source/filter/html/wrthtml.cxx +++ b/sw/source/filter/html/wrthtml.cxx @@ -81,6 +81,7 @@ #include <IDocumentSettingAccess.hxx> #include <IDocumentStylePoolAccess.hxx> #include <xmloff/odffields.hxx> +#include <tools/urlobj.hxx> #define MAX_INDENT_LEVEL 20 @@ -1197,7 +1198,8 @@ OUString SwHTMLWriter::convertHyperlinkHRefValue(const OUString& rURL) } } } - return URIHelper::simpleNormalizedMakeRelative(GetBaseURL(), sURL); + INetURLObject aURL( sURL ); + return URIHelper::simpleNormalizedMakeRelative( GetBaseURL(), aURL.GetMainURL( INetURLObject::NO_DECODE ) ); } void SwHTMLWriter::OutHyperlinkHRefValue( const OUString& rURL ) |