| 174 | } |
| 175 | |
| 176 | void close_input(JNIEnv* e, SOCKET sock) |
| 177 | { |
| 178 | if (SOCKET_ERROR == ::shutdown(sock, SD_RECEIVE)) { |
| 179 | int errcode = last_socket_error(); |
| 180 | if (errcode != ENOTCONN) { |
| 181 | char buf[255]; |
| 182 | sprintf(buf, "Can't shutdown the socket. System error: %d", errcode); |
| 183 | throwNew(e, "java/io/IOException", buf); |
| 184 | } |
| 185 | } |
| 186 | } |
| 187 | |
| 188 | void close_output(JNIEnv* e, SOCKET sock) |
| 189 | { |
no test coverage detected