| 215 | } |
| 216 | |
| 217 | bool Client::initClientSocket(SocketClient &client, const std::string &ipAddr, int port) { |
| 218 | |
| 219 | client.setupSocketStructure(ipAddr, port); |
| 220 | |
| 221 | if (!client.setupSocketHandle(SOCK_STREAM /*| SOCK_NONBLOCK*/, 0)) { |
| 222 | SI_LOG_ERROR("OSCam Server handle failed"); |
| 223 | return false; |
| 224 | } |
| 225 | |
| 226 | client.setSocketTimeoutInSec(2); |
| 227 | |
| 228 | if (!client.connectTo()) { |
| 229 | SI_LOG_ERROR("Connecting to OSCam Server failed"); |
| 230 | return false; |
| 231 | } |
| 232 | return true; |
| 233 | } |
| 234 | |
| 235 | void Client::sendClientInfo() { |
| 236 | std::string name = "SatPI "; |
nothing calls this directly
no test coverage detected