摘要:
int iConn = 0; if (state1.sck1 != null) { if (state1.sck1.Connected) { if (state1.sck1.Poll(500, SelectMode.SelectRead)) { iConn = state1.sck1.Receive(state1.acBuff); if (iConn == 0) { //socket连接已断开 } } else { iConn = 1; //连接 } } } 阅读全文