summaryrefslogtreecommitdiff
path: root/ucb
diff options
context:
space:
mode:
authorStephan Bergmann <sbergman@redhat.com>2014-01-21 15:53:55 +0100
committerCaolán McNamara <caolanm@redhat.com>2014-01-21 16:01:07 +0000
commit523ad9696c9135a29393a0c4d147ab206b6de4f5 (patch)
treefe30ff35cc11890a2345d75495c455f792a4bf56 /ucb
parent7713dfc9b50b88cf2548d49e65b099a6a81e9d65 (diff)
Fix bogus mass-conversion equalsAsciiL -> startsWith
3af99e4d59d89c343965a928681a30f36b1007d2 "convert equalsAsciiL calls to startsWith calls" should rather have converted to oprator ==. (cherry picked from commit a3f32769fc4bb23c64168b412dd10ec769a3854d) Conflicts: sc/source/ui/unoobj/nameuno.cxx sc/source/ui/unoobj/styleuno.cxx sfx2/source/appl/sfxhelp.cxx stoc/source/security/permissions.cxx sw/source/core/unocore/unocrsrhelper.cxx (None of those bogus startsWith calls seem problematic enough to warrant backporting also to libreoffice-4-2-0.) Change-Id: Id4a8836c5d6d570e54661c40be7214632e202b21 Reviewed-on: https://gerrit.libreoffice.org/7578 Reviewed-by: Caolán McNamara <caolanm@redhat.com> Tested-by: Caolán McNamara <caolanm@redhat.com>
Diffstat (limited to 'ucb')
-rw-r--r--ucb/source/ucp/webdav/webdavcontent.cxx20
1 files changed, 10 insertions, 10 deletions
diff --git a/ucb/source/ucp/webdav/webdavcontent.cxx b/ucb/source/ucp/webdav/webdavcontent.cxx
index 07ecebe0730b..9bd49f36cfb8 100644
--- a/ucb/source/ucp/webdav/webdavcontent.cxx
+++ b/ucb/source/ucp/webdav/webdavcontent.cxx
@@ -97,7 +97,7 @@ static void lcl_sendPartialGETRequest( bool &bError,
for ( std::vector< rtl::OUString >::const_iterator it = aHeaderNames.begin();
it != aHeaderNames.end(); ++it )
{
- if ( it->startsWith( "Content-Length" ) )
+ if ( *it == "Content-Length" )
{
bIsRequestSize = true;
break;
@@ -129,11 +129,11 @@ static void lcl_sendPartialGETRequest( bool &bError,
for ( std::vector< DAVPropertyValue >::const_iterator it = aResponseProps.begin();
it != aResponseProps.end(); ++it )
{
- if ( it->Name.startsWith( "Accept-Ranges" ) )
+ if ( it->Name == "Accept-Ranges" )
it->Value >>= aAcceptRanges;
- else if ( it->Name.startsWith( "Content-Range" ) )
+ else if ( it->Name == "Content-Range" )
it->Value >>= aContentRange;
- else if ( it->Name.startsWith( "Content-Length" ) )
+ else if ( it->Name == "Content-Length" )
it->Value >>= aContentLength;
}
@@ -148,7 +148,7 @@ static void lcl_sendPartialGETRequest( bool &bError,
// MAY ignore ranges specified using other units.
if ( nSize == 1 &&
aContentRange.getLength() &&
- aAcceptRanges.startsWith( "bytes" ) )
+ aAcceptRanges == "bytes" )
{
// Parse the Content-Range to get the size
// vid. http://tools.ietf.org/html/rfc2616#section-14.16
@@ -158,12 +158,12 @@ static void lcl_sendPartialGETRequest( bool &bError,
{
rtl::OUString aSize = aContentRange.copy( nSlash + 1 );
// "*" means that the instance-length is unknown at the time when the response was generated
- if ( !aSize.startsWith( "*" ))
+ if ( aSize != "*" )
{
for ( std::vector< DAVPropertyValue >::iterator it = aResponseProps.begin();
it != aResponseProps.end(); ++it )
{
- if ( it->Name.startsWith( "Content-Length" ) )
+ if ( it->Name != "Content-Length" )
{
it->Value <<= aSize;
break;
@@ -743,7 +743,7 @@ uno::Any SAL_CALL Content::execute(
aRet = uno::makeAny( createNewContent( aArg ) );
}
- else if ( aCommand.Name.startsWith( "addProperty" ))
+ else if ( aCommand.Name == "addProperty" )
{
ucb::PropertyCommandArgument aPropArg;
if ( !( aCommand.Argument >>= aPropArg ))
@@ -775,7 +775,7 @@ uno::Any SAL_CALL Content::execute(
ucbhelper::cancelCommandExecution( uno::makeAny( e ), Environment );
}
}
- else if ( aCommand.Name.startsWith( "removeProperty" ))
+ else if ( aCommand.Name == "removeProperty" )
{
rtl::OUString sPropName;
if ( !( aCommand.Argument >>= sPropName ) )
@@ -1893,7 +1893,7 @@ uno::Sequence< uno::Any > Content::setPropertyValues(
"Property is read-only!" ),
static_cast< cppu::OWeakObject * >( this ) );
}
- if ( rName.startsWith( "CreatableContentsInfo" ) )
+ if ( rName == "CreatableContentsInfo" )
{
// Read-only property!
aRet[ n ] <<= lang::IllegalAccessException(