---------------------------------------------------------------------------
| 34 | } |
| 35 | //--------------------------------------------------------------------------- |
| 36 | bool MSocket::Close(void) |
| 37 | { |
| 38 | if( !handle || !Connected ) return true; |
| 39 | /* |
| 40 | * WinSock 2 extension -- manifest constants for shutdown() |
| 41 | #define SD_RECEIVE 0x00 |
| 42 | #define SD_SEND 0x01 |
| 43 | #define SD_BOTH 0x02 |
| 44 | */ |
| 45 | shutdown(handle, 0x02); // SD_SEND |
| 46 | Error = closesocket(handle); |
| 47 | handle = NULL; |
| 48 | Connected = false; |
| 49 | return ! Error; |
| 50 | } |
| 51 | //--------------------------------------------------------------------------- |
| 52 | bool MSocket::Write(void * data, int size) |
| 53 | { |
nothing calls this directly
no outgoing calls
no test coverage detected