summaryrefslogtreecommitdiff
path: root/tools/source
diff options
context:
space:
mode:
authorNoel Grandin <noelgrandin@gmail.com>2017-05-28 19:41:52 +0200
committerNoel Grandin <noel.grandin@collabora.co.uk>2017-08-17 11:55:13 +0200
commit9881bea8d41997fb46579eb5f0314300159c96cc (patch)
treef52daa7055d2d28959e2d1ad576d963b7c0d3b2d /tools/source
parentec4034c4a4f23574401ba2a74b635d9ed4befbc8 (diff)
remove unnecessary use of OUString::getStr
Change-Id: I3d13e1c0bb6aa4a7aacc463198747c1368ebc9b4 Reviewed-on: https://gerrit.libreoffice.org/38114 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
Diffstat (limited to 'tools/source')
-rw-r--r--tools/source/fsys/urlobj.cxx2
-rw-r--r--tools/source/inet/inetmime.cxx4
2 files changed, 4 insertions, 2 deletions
diff --git a/tools/source/fsys/urlobj.cxx b/tools/source/fsys/urlobj.cxx
index 544ec38cbf0b..eeadb7df38d2 100644
--- a/tools/source/fsys/urlobj.cxx
+++ b/tools/source/fsys/urlobj.cxx
@@ -597,7 +597,7 @@ std::unique_ptr<SvMemoryStream> INetURLObject::getData()
}
OUString sURLPath = GetURLPath( DecodeMechanism::WithCharset, RTL_TEXTENCODING_ISO_8859_1 );
- sal_Unicode const * pSkippedMediatype = INetMIME::scanContentType( sURLPath.getStr(), sURLPath.getStr() + sURLPath.getLength() );
+ sal_Unicode const * pSkippedMediatype = INetMIME::scanContentType( sURLPath );
sal_Int32 nCharactersSkipped = pSkippedMediatype == nullptr
? 0 : pSkippedMediatype-sURLPath.getStr();
if (sURLPath.match(",", nCharactersSkipped))
diff --git a/tools/source/inet/inetmime.cxx b/tools/source/inet/inetmime.cxx
index a398aa79e3ca..0be1ee62d8b2 100644
--- a/tools/source/inet/inetmime.cxx
+++ b/tools/source/inet/inetmime.cxx
@@ -1088,9 +1088,11 @@ bool INetMIME::scanUnsigned(const sal_Unicode *& rBegin,
// static
sal_Unicode const * INetMIME::scanContentType(
- sal_Unicode const * pBegin, sal_Unicode const * pEnd, OUString * pType,
+ OUString const & rStr, OUString * pType,
OUString * pSubType, INetContentTypeParameterList * pParameters)
{
+ sal_Unicode const * pBegin = rStr.getStr();
+ sal_Unicode const * pEnd = pBegin + rStr.getLength();
sal_Unicode const * p = skipLinearWhiteSpaceComment(pBegin, pEnd);
sal_Unicode const * pTypeBegin = p;
while (p != pEnd && isTokenChar(*p))