connectivity/source/drivers/ado/AConnection.cxx |    3 +--
 1 file changed, 1 insertion(+), 2 deletions(-)

New commits:
commit d81c26a1b9220c176f2d7162ac3b01983d6c8e4f
Author:     Stephan Bergmann <sberg...@redhat.com>
AuthorDate: Wed Apr 20 21:40:49 2022 +0200
Commit:     Stephan Bergmann <sberg...@redhat.com>
CommitDate: Wed Apr 20 22:51:02 2022 +0200

    Simplify some code, use o3tl::starts_with rest argument
    
    Change-Id: I3eede83bdea26a6ac8ff81e664c0439b75879ccf
    Reviewed-on: https://gerrit.libreoffice.org/c/core/+/133225
    Tested-by: Jenkins
    Reviewed-by: Stephan Bergmann <sberg...@redhat.com>

diff --git a/connectivity/source/drivers/ado/AConnection.cxx 
b/connectivity/source/drivers/ado/AConnection.cxx
index 2756a4c5d0d9..686a9fed58aa 100644
--- a/connectivity/source/drivers/ado/AConnection.cxx
+++ b/connectivity/source/drivers/ado/AConnection.cxx
@@ -93,8 +93,7 @@ void OConnection::construct(std::u16string_view url,const 
Sequence< PropertyValu
     nLen = url.find(':',nLen == std::u16string_view::npos ? 0 : nLen+1);
     std::u16string_view aDSN(url.substr(nLen == std::u16string_view::npos ? 0 
: nLen+1));
     OUString aUID,aPWD;
-    if ( o3tl::starts_with(aDSN, u"access:") )
-        aDSN.remove_prefix(7);
+    o3tl::starts_with(aDSN, u"access:", &aDSN);
 
     sal_Int32 nTimeout = 20;
     const PropertyValue *pIter  = info.getConstArray();

Reply via email to