[Libreoffice-commits] core.git: sal/osl

Stephan Bergmann sbergman at redhat.com
Tue Aug 29 06:36:15 UTC 2017


 sal/osl/w32/socket.cxx |    4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

New commits:
commit 52403e5087d68748f58eb4bf2b94eba7fbf21540
Author: Stephan Bergmann <sbergman at redhat.com>
Date:   Tue Aug 29 08:32:43 2017 +0200

    loplugin:cstylecast/nullptr (clang-cl)
    
    Change-Id: I04be0f4fe8c98909b37586080096ee05341f956f

diff --git a/sal/osl/w32/socket.cxx b/sal/osl/w32/socket.cxx
index b1d8af3a9970..97c8ffee2987 100644
--- a/sal/osl/w32/socket.cxx
+++ b/sal/osl/w32/socket.cxx
@@ -793,9 +793,9 @@ oslSocket SAL_CALL osl_createSocket(
         int nErrno = WSAGetLastError();
         wchar_t *sErr = nullptr;
         FormatMessageW(FORMAT_MESSAGE_ALLOCATE_BUFFER | FORMAT_MESSAGE_FROM_SYSTEM | FORMAT_MESSAGE_IGNORE_INSERTS,
-                       NULL, nErrno,
+                       nullptr, nErrno,
                        MAKELANGID(LANG_NEUTRAL, SUBLANG_DEFAULT),
-                       (LPWSTR)&sErr, 0, NULL);
+                       reinterpret_cast<LPWSTR>(&sErr), 0, nullptr);
         SAL_WARN("sal.osl", "socket creation failed: (" << nErrno << ") " << sErr);
         LocalFree(sErr);
 


More information about the Libreoffice-commits mailing list