CAsynSocket的问题
kirk 2000-08-30 08:20:00 我需要在SOCKET被CLOSE后马上重新连接,因此在派生类中加入了如下代码:
void CMyAsySocket::OnClose(int nErrorCode)
{
// TODO: Add your specialized code here and/or call the base
CAsyncSocket::OnClose(nErrorCode);
Connect(m_strMyAddress, m_iPort);
}
可是没有用,为什么?