[Libreoffice-commits] core.git: sal/osl
Stephan Bergmann
sbergman at redhat.com
Mon Aug 28 08:21:59 UTC 2017
sal/osl/unx/socket.cxx | 4 ++--
sal/osl/w32/socket.cxx | 2 +-
2 files changed, 3 insertions(+), 3 deletions(-)
New commits:
commit 8b63825dc2e2c271b9109c32a27e1ea246f7d87e
Author: Stephan Bergmann <sbergman at redhat.com>
Date: Mon Aug 28 10:17:35 2017 +0200
Fix type of errno/WSAGetLastError()
...as got broken with 3d5be8cd31bcf6fce8772133298d2ae076361362 "osl: give
warning on socket error (win32), move Flag definition (unx)"
Change-Id: Ib68540596b0bc2cda3e809e765c7d41ca45dda71
diff --git a/sal/osl/unx/socket.cxx b/sal/osl/unx/socket.cxx
index b3ca2bb83191..f7a98efafc82 100644
--- a/sal/osl/unx/socket.cxx
+++ b/sal/osl/unx/socket.cxx
@@ -1153,7 +1153,7 @@ oslSocket SAL_CALL osl_createSocket(
/* creation failed => free memory */
if(pSocket->m_Socket == OSL_INVALID_SOCKET)
{
- sal_Int32 nErrno = errno;
+ int nErrno = errno;
SAL_WARN( "sal.osl", "socket creation failed: (" << nErrno << ") " << strerror(nErrno) );
destroySocketImpl(pSocket);
@@ -1169,7 +1169,7 @@ oslSocket SAL_CALL osl_createSocket(
if (fcntl(pSocket->m_Socket, F_SETFD, nFlags) == -1)
{
pSocket->m_nLastError=errno;
- sal_uInt32 nErrno = errno;
+ int nErrno = errno;
SAL_WARN( "sal.osl", "failed changing socket flags: (" << nErrno << ") " << strerror(nErrno) );
}
}
diff --git a/sal/osl/w32/socket.cxx b/sal/osl/w32/socket.cxx
index 6ae42e557515..b1d8af3a9970 100644
--- a/sal/osl/w32/socket.cxx
+++ b/sal/osl/w32/socket.cxx
@@ -790,7 +790,7 @@ oslSocket SAL_CALL osl_createSocket(
/* creation failed => free memory */
if(pSocket->m_Socket == OSL_INVALID_SOCKET)
{
- sal_uInt32 nErrno = WSAGetLastError();
+ int nErrno = WSAGetLastError();
wchar_t *sErr = nullptr;
FormatMessageW(FORMAT_MESSAGE_ALLOCATE_BUFFER | FORMAT_MESSAGE_FROM_SYSTEM | FORMAT_MESSAGE_IGNORE_INSERTS,
NULL, nErrno,
More information about the Libreoffice-commits
mailing list