Browse Source

Silence some warnings

Signed-off-by: falkTX <falktx@falktx.com>
pull/1780/head
falkTX 1 year ago
parent
commit
a35ab6504f
Signed by: falkTX <falktx@falktx.com> GPG Key ID: CDBAA37ABC74FBA0
1 changed files with 8 additions and 8 deletions
  1. +8
    -8
      source/utils/CarlaPipeUtils.cpp

+ 8
- 8
source/utils/CarlaPipeUtils.cpp View File

@@ -118,7 +118,7 @@ bool waitForAsyncObject(const HANDLE object, const HANDLE process = INVALID_HAND
}

static inline
ssize_t ReadFileWin32(const HANDLE pipeh, const HANDLE event, void* const buf, const std::size_t numBytes)
ssize_t ReadFileWin32(const HANDLE pipeh, const HANDLE event, void* const buf, const DWORD numBytes)
{
DWORD dw, dsize = numBytes;
DWORD available = 0;
@@ -165,7 +165,7 @@ ssize_t ReadFileWin32(const HANDLE pipeh, const HANDLE event, void* const buf, c
}

static inline
ssize_t WriteFileWin32(const HANDLE pipeh, const HANDLE event, const void* const buf, const std::size_t numBytes)
ssize_t WriteFileWin32(const HANDLE pipeh, const HANDLE event, const void* const buf, const DWORD numBytes)
{
DWORD dw, dsize = numBytes;

@@ -1434,20 +1434,20 @@ bool CarlaPipeCommon::_writeMsgBuffer(const char* const msg, const std::size_t s
ssize_t ret;

try {
#ifdef CARLA_OS_WIN
ret = WriteFileWin32(pData->pipeSend, pData->ovSend, msg, size);
#else
#ifdef CARLA_OS_WIN
ret = WriteFileWin32(pData->pipeSend, pData->ovSend, msg, static_cast<DWORD>(size));
#else
ret = ::write(pData->pipeSend, msg, size);
#endif
#endif
} CARLA_SAFE_EXCEPTION_RETURN("CarlaPipeCommon::writeMsgBuffer", false);

#ifdef CARLA_OS_WIN
#ifdef CARLA_OS_WIN
if (ret == -2)
{
pData->pipeClosed = true;
return false;
}
#endif
#endif

if (ret == static_cast<ssize_t>(size))
{


Loading…
Cancel
Save