extensions/source/config/ldap/ldapaccess.cxx     |   12 ++++++------
 extensions/source/ole/unoconversionutilities.hxx |    3 ++-
 2 files changed, 8 insertions(+), 7 deletions(-)

New commits:
commit db05d1adfdac550ea8bf179686e65bebc8b349f7
Author: Stephan Bergmann <sberg...@redhat.com>
Date:   Fri May 12 13:25:06 2017 +0200

    Clean up uses of SAL_U/SAL_W: extensions
    
    Change-Id: I08716e6976e205247064622cd9db46f5364a8c8c

diff --git a/extensions/source/config/ldap/ldapaccess.cxx 
b/extensions/source/config/ldap/ldapaccess.cxx
index 5d2982315f25..d24f66e28c1b 100644
--- a/extensions/source/config/ldap/ldapaccess.cxx
+++ b/extensions/source/config/ldap/ldapaccess.cxx
@@ -131,8 +131,8 @@ void  LdapConnection::connectSimple()
         // Do the bind
 #ifdef _WIN32
         LdapErrCode retCode = ldap_simple_bind_sW(mConnection,
-                                               SAL_W(const_cast<sal_Unicode 
*>(mLdapDefinition.mAnonUser.getStr())),
-                                               SAL_W(const_cast<sal_Unicode 
*>(mLdapDefinition.mAnonCredentials.getStr())) );
+                                               reinterpret_cast<wchar_t 
*>(const_cast<sal_Unicode *>(mLdapDefinition.mAnonUser.getStr())),
+                                               reinterpret_cast<wchar_t 
*>(const_cast<sal_Unicode *>(mLdapDefinition.mAnonCredentials.getStr())) );
 #else
         LdapErrCode retCode = ldap_simple_bind_s(mConnection,
                                                OUStringToOString( 
mLdapDefinition.mAnonUser, RTL_TEXTENCODING_UTF8 ).getStr(),
@@ -153,7 +153,7 @@ void LdapConnection::initConnection()
     if (mLdapDefinition.mPort == 0) mLdapDefinition.mPort = LDAP_PORT;
 
 #ifdef _WIN32
-    mConnection = ldap_initW(SAL_W(const_cast<sal_Unicode 
*>(mLdapDefinition.mServer.getStr())),
+    mConnection = ldap_initW(reinterpret_cast<wchar_t 
*>(const_cast<sal_Unicode *>(mLdapDefinition.mServer.getStr())),
                             mLdapDefinition.mPort) ;
 #else
     mConnection = ldap_init(OUStringToOString( mLdapDefinition.mServer, 
RTL_TEXTENCODING_UTF8 ).getStr(),
@@ -178,7 +178,7 @@ void LdapConnection::initConnection()
     LdapMessageHolder result;
 #ifdef _WIN32
     LdapErrCode retCode = ldap_search_sW(mConnection,
-                                      SAL_W(const_cast<sal_Unicode 
*>(aUserDn.getStr())),
+                                      reinterpret_cast<wchar_t 
*>(const_cast<sal_Unicode *>(aUserDn.getStr())),
                                       LDAP_SCOPE_BASE,
                                       const_cast<PWCHAR>( L"(objectclass=*)" ),
                                       nullptr,
@@ -245,9 +245,9 @@ void LdapConnection::initConnection()
 #ifdef _WIN32
     PWCHAR attributes [2] = { const_cast<PWCHAR>( L"1.1" ), nullptr };
     LdapErrCode retCode = ldap_search_sW(mConnection,
-                                      SAL_W(const_cast<sal_Unicode 
*>(mLdapDefinition.mBaseDN.getStr())),
+                                      reinterpret_cast<wchar_t 
*>(const_cast<sal_Unicode *>(mLdapDefinition.mBaseDN.getStr())),
                                       LDAP_SCOPE_SUBTREE,
-                                      SAL_W(const_cast<sal_Unicode 
*>(filter.makeStringAndClear().getStr())), attributes, 0, &result.msg) ;
+                                      reinterpret_cast<wchar_t 
*>(const_cast<sal_Unicode *>(filter.makeStringAndClear().getStr())), 
attributes, 0, &result.msg) ;
 #else
     sal_Char * attributes [2] = { const_cast<sal_Char *>(LDAP_NO_ATTRS), 
nullptr };
     LdapErrCode retCode = ldap_search_s(mConnection,
diff --git a/extensions/source/ole/unoconversionutilities.hxx 
b/extensions/source/ole/unoconversionutilities.hxx
index 0249e5222124..58a2d9dcfb27 100644
--- a/extensions/source/ole/unoconversionutilities.hxx
+++ b/extensions/source/ole/unoconversionutilities.hxx
@@ -1993,7 +1993,8 @@ void 
UnoConversionUtilities<T>::dispatchExObject2Sequence( const VARIANTARG* pva
         for( sal_Int32 i= 0; i< length; i++)
         {
             OUString ousIndex=OUString::number( i);
-            OLECHAR* sindex = SAL_W(const_cast<sal_Unicode 
*>(ousIndex.getStr()));
+            OLECHAR* sindex = reinterpret_cast<wchar_t *>(
+                const_cast<sal_Unicode *>(ousIndex.getStr()));
 
             if( FAILED( hr= pdispEx->GetIDsOfNames(IID_NULL, &sindex , 1, 
LOCALE_USER_DEFAULT, &dispid)))
             {
_______________________________________________
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits

Reply via email to