summaryrefslogtreecommitdiff
path: root/cpp/src/IceSSL/TransceiverI.cpp
diff options
context:
space:
mode:
authorBernard Normier <bernard@zeroc.com>2012-12-26 19:45:20 -0500
committerBernard Normier <bernard@zeroc.com>2012-12-26 19:45:20 -0500
commit4e404c3bc3e148f056459dd02ebb811c5f37abac (patch)
treedfdc221b8bee33b556d17c09814591bcc95db7ef /cpp/src/IceSSL/TransceiverI.cpp
parentcompact ID support for scripting languages (diff)
downloadice-4e404c3bc3e148f056459dd02ebb811c5f37abac.tar.bz2
ice-4e404c3bc3e148f056459dd02ebb811c5f37abac.tar.xz
ice-4e404c3bc3e148f056459dd02ebb811c5f37abac.zip
Fixed mingw warnings and added -Werror to mingw build
Diffstat (limited to 'cpp/src/IceSSL/TransceiverI.cpp')
-rw-r--r--cpp/src/IceSSL/TransceiverI.cpp16
1 files changed, 13 insertions, 3 deletions
diff --git a/cpp/src/IceSSL/TransceiverI.cpp b/cpp/src/IceSSL/TransceiverI.cpp
index db134aa1d2a..a4e21e73ceb 100644
--- a/cpp/src/IceSSL/TransceiverI.cpp
+++ b/cpp/src/IceSSL/TransceiverI.cpp
@@ -722,7 +722,10 @@ IceSSL::TransceiverI::startRead(IceInternal::Buffer& buf)
assert(!BIO_ctrl_get_read_request(_iocpBio));
ERR_clear_error(); // Clear any spurious errors.
- int ret = SSL_read(_ssl, reinterpret_cast<void*>(&*buf.i), static_cast<int>(buf.b.end() - buf.i));
+#ifndef NDEBUG
+ int ret =
+#endif
+ SSL_read(_ssl, reinterpret_cast<void*>(&*buf.i), static_cast<int>(buf.b.end() - buf.i));
assert(ret <= 0 && SSL_get_error(_ssl, ret) == SSL_ERROR_WANT_READ);
assert(BIO_ctrl_get_read_request(_iocpBio));
@@ -1001,7 +1004,11 @@ IceSSL::TransceiverI::receive()
}
assert(_readI == _readBuffer.end());
- int n = BIO_write(_iocpBio, &_readBuffer[0], static_cast<int>(_readBuffer.size()));
+#ifndef NDEBUG
+ int n =
+#endif
+ BIO_write(_iocpBio, &_readBuffer[0], static_cast<int>(_readBuffer.size()));
+
assert(n == static_cast<int>(_readBuffer.size()));
return true;
}
@@ -1013,7 +1020,10 @@ IceSSL::TransceiverI::send()
{
assert(BIO_ctrl_pending(_iocpBio));
_writeBuffer.resize(BIO_ctrl_pending(_iocpBio));
- int n = BIO_read(_iocpBio, &_writeBuffer[0], static_cast<int>(_writeBuffer.size()));
+#ifndef NDEBUG
+ int n =
+#endif
+ BIO_read(_iocpBio, &_writeBuffer[0], static_cast<int>(_writeBuffer.size()));
assert(n == static_cast<int>(_writeBuffer.size()));
_writeI = _writeBuffer.begin();
}