Changeset 11164
- Timestamp:
- 06/24/11 12:27:51 (13 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/FACT++/src/Connection.cc
r11118 r11164 65 65 66 66 // AsyncConnect + Deadline 67 async_connect(endpoint,67 async_connect(endpoint, 68 68 boost::bind(&Connection::ConnectImp, 69 69 this, ba::placeholders::error, … … 286 286 if (!error) 287 287 { 288 Info("Connection established to "+host+"..."); 288 set_option(socket_base::keep_alive(true)); 289 290 const int optval = 10; 291 // First keep alive after 10s 292 setsockopt(native(), SOL_TCP, TCP_KEEPIDLE, &optval, sizeof(optval)); 293 // New keep alive after 10s 294 setsockopt(native(), SOL_TCP, TCP_KEEPINTVL, &optval, sizeof(optval)); 295 296 Info("Connection established to "+host+"..."); 289 297 290 298 fConnectionStatus = kConnected;
Note:
See TracChangeset
for help on using the changeset viewer.