diff options
author | Benoit Foucher <benoit@zeroc.com> | 2009-08-21 15:55:01 +0200 |
---|---|---|
committer | Benoit Foucher <benoit@zeroc.com> | 2009-08-21 15:55:01 +0200 |
commit | b9f2fa14fb3f222a6ec5e0a93bf25fe5ad12b56a (patch) | |
tree | 183215e2dbeadfbc871b800ce09726e58af38b91 /cpp/src/Ice/TcpConnector.cpp | |
parent | adding compression cookbook demo (diff) | |
download | ice-b9f2fa14fb3f222a6ec5e0a93bf25fe5ad12b56a.tar.bz2 ice-b9f2fa14fb3f222a6ec5e0a93bf25fe5ad12b56a.tar.xz ice-b9f2fa14fb3f222a6ec5e0a93bf25fe5ad12b56a.zip |
IOCP changes, bug 3501, 4200, 4156, 3101
Diffstat (limited to 'cpp/src/Ice/TcpConnector.cpp')
-rw-r--r-- | cpp/src/Ice/TcpConnector.cpp | 16 |
1 files changed, 3 insertions, 13 deletions
diff --git a/cpp/src/Ice/TcpConnector.cpp b/cpp/src/Ice/TcpConnector.cpp index 310e58bc058..9d45fdf82bd 100644 --- a/cpp/src/Ice/TcpConnector.cpp +++ b/cpp/src/Ice/TcpConnector.cpp @@ -31,19 +31,9 @@ IceInternal::TcpConnector::connect() try { - SOCKET fd = createSocket(false, _addr.ss_family); - setBlock(fd, false); - setTcpBufSize(fd, _instance->initializationData().properties, _logger); - bool connected = doConnect(fd, _addr); - if(connected) - { - if(_traceLevels->network >= 1) - { - Trace out(_logger, _traceLevels->networkCat); - out << "tcp connection established\n" << fdToString(fd); - } - } - return new TcpTransceiver(_instance, fd, connected); + TransceiverPtr transceiver = new TcpTransceiver(_instance, createSocket(false, _addr.ss_family), false); + dynamic_cast<TcpTransceiver*>(transceiver.get())->connect(_addr); + return transceiver; } catch(const Ice::LocalException& ex) { |