diff options
Diffstat (limited to 'cpp/src/IceSSL/TransceiverI.cpp')
-rw-r--r-- | cpp/src/IceSSL/TransceiverI.cpp | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/cpp/src/IceSSL/TransceiverI.cpp b/cpp/src/IceSSL/TransceiverI.cpp index ffa74ed4914..512691d0b69 100644 --- a/cpp/src/IceSSL/TransceiverI.cpp +++ b/cpp/src/IceSSL/TransceiverI.cpp @@ -80,8 +80,8 @@ IceSSL::TransceiverI::shutdownReadWrite() void IceSSL::TransceiverI::write(IceInternal::Buffer& buf, int timeout) { - IceInternal::Buffer::Container::difference_type packetSize = - static_cast<IceInternal::Buffer::Container::difference_type>(buf.b.end() - buf.i); + // Its impossible for the packetSize to be more than an Int. + int packetSize = static_cast<int>(buf.b.end() - buf.i); #ifdef _WIN32 // @@ -206,7 +206,7 @@ IceSSL::TransceiverI::write(IceInternal::Buffer& buf, int timeout) if(packetSize > buf.b.end() - buf.i) { - packetSize = static_cast<IceInternal::Buffer::Container::difference_type>(buf.b.end() - buf.i); + packetSize = static_cast<int>(buf.b.end() - buf.i); } } } @@ -214,8 +214,8 @@ IceSSL::TransceiverI::write(IceInternal::Buffer& buf, int timeout) void IceSSL::TransceiverI::read(IceInternal::Buffer& buf, int timeout) { - IceInternal::Buffer::Container::difference_type packetSize = - static_cast<IceInternal::Buffer::Container::difference_type>(buf.b.end() - buf.i); + // Its impossible for the packetSize to be more than an Int. + int packetSize = static_cast<int>(buf.b.end() - buf.i); while(buf.i != buf.b.end()) { @@ -349,7 +349,7 @@ IceSSL::TransceiverI::read(IceInternal::Buffer& buf, int timeout) if(packetSize > buf.b.end() - buf.i) { - packetSize = static_cast<IceInternal::Buffer::Container::difference_type>(buf.b.end() - buf.i); + packetSize = static_cast<int>(buf.b.end() - buf.i); } } } |