summaryrefslogtreecommitdiff
path: root/cppuhelper
diff options
context:
space:
mode:
authorChristophe JAILLET <christophe.jaillet@wanadoo.fr>2012-07-12 23:30:30 +0200
committerEike Rathke <erack@redhat.com>2012-07-13 16:36:04 +0200
commit0cba5e5d25bf2f30c8500e1e673a7ef9e8e8d352 (patch)
treefbaff78064c30bfab0de0cd0757ff431b447cb83 /cppuhelper
parent06b6a1da4a19108d0988ebe49c680905ae27d721 (diff)
This look like the same as rLibName.endsWithIgnoreAsciiCase so kill it. Add missing { }
Untested as I don't have a working build environment yet. Change-Id: I1988da8c07729eb99d3f53f71b8f950df29a7361
Diffstat (limited to 'cppuhelper')
-rw-r--r--cppuhelper/source/shlib.cxx21
1 files changed, 4 insertions, 17 deletions
diff --git a/cppuhelper/source/shlib.cxx b/cppuhelper/source/shlib.cxx
index 7d871423062d..f783f870c62d 100644
--- a/cppuhelper/source/shlib.cxx
+++ b/cppuhelper/source/shlib.cxx
@@ -210,19 +210,6 @@ static bool checkAccessPath( OUString * pComp ) throw ()
}
//------------------------------------------------------------------------------
-static inline sal_Int32 endsWith(
- const OUString & rText, const OUString & rEnd ) SAL_THROW(())
-{
- if (rText.getLength() >= rEnd.getLength() &&
- rEnd.equalsIgnoreAsciiCase(
- rText.copy( rText.getLength() - rEnd.getLength() ) ))
- {
- return rText.getLength() - rEnd.getLength();
- }
- return -1;
-}
-
-//------------------------------------------------------------------------------
static OUString makeComponentPath(
const OUString & rLibName, const OUString & rPath )
{
@@ -247,13 +234,13 @@ static OUString makeComponentPath(
if (rPath[ rPath.getLength() -1 ] != '/')
buf.append( (sal_Unicode) '/' );
}
- sal_Int32 nEnd = endsWith( rLibName, OUSTR(SAL_DLLEXTENSION) );
- if (nEnd < 0) // !endsWith
+ if (! rLibName.endsWithIgnoreAsciiCase( OUSTR(SAL_DLLEXTENSION) ))
{
#if defined SAL_DLLPREFIX
- nEnd = endsWith( rLibName, OUSTR(".uno") );
- if (nEnd < 0) // !endsWith
+ if (! rLibName.endsWithIgnoreAsciiCase( OUSTR(".uno") ))
+ {
buf.appendAscii( RTL_CONSTASCII_STRINGPARAM(SAL_DLLPREFIX) );
+ }
#endif
buf.append( rLibName );
buf.appendAscii( RTL_CONSTASCII_STRINGPARAM(SAL_DLLEXTENSION) );