diff options
author | David Tardon <dtardon@redhat.com> | 2014-07-14 15:07:52 +0200 |
---|---|---|
committer | Eike Rathke <erack@redhat.com> | 2014-07-22 17:06:16 +0000 |
commit | 40eddf707f8f56fa63ddba9f4713a32dba43bd62 (patch) | |
tree | 6ba25e35a020b62f27eabc4955d8f207b4d68489 | |
parent | 32aa2a2a945c66951627bd5e0fc568ab9adbfc81 (diff) |
fdo#81304 don't parse file name as part of URL
... because the name is not URL-encoded at this point, so parsing it as
a part of the URL will interpret special characters, e.g. #.
Change-Id: I780baed1753e9674d835dc296d31c088b67d8ba7
(cherry picked from commit f3d7734af45f30a87d6de76aa3de7593d541bdc8)
Reviewed-on: https://gerrit.libreoffice.org/10294
Reviewed-by: Eike Rathke <erack@redhat.com>
Tested-by: Eike Rathke <erack@redhat.com>
-rw-r--r-- | sfx2/source/doc/guisaveas.cxx | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/sfx2/source/doc/guisaveas.cxx b/sfx2/source/doc/guisaveas.cxx index 85a9947c267a..b8d487d0501c 100644 --- a/sfx2/source/doc/guisaveas.cxx +++ b/sfx2/source/doc/guisaveas.cxx @@ -1279,7 +1279,8 @@ OUString ModelData_Impl::GetRecommendedName( const OUString& aSuggestedName, con uno::UNO_QUERY ); if ( xTypeDetection.is() ) { - INetURLObject aObj( OUString( "file:///c:/" ) + aRecommendedName ); + INetURLObject aObj( OUString( "file:///c:/" ) ); + aObj.SetName( aRecommendedName ); uno::Sequence< beans::PropertyValue > aTypeNameProps; if ( ( xTypeDetection->getByName( aTypeName ) >>= aTypeNameProps ) && aTypeNameProps.getLength() ) |