When reconnecting a never-connected socket with a next layer [ssl], state is unconnected, not notsock. Source commit: b7e4e52d7906e2f8145f5783e6ff7c62310a2807
@@ -720,7 +720,7 @@ BOOL CAsyncSocketExLayer::Create(UINT nSocketPort, int nSocketType,
BOOL CAsyncSocketExLayer::CreateNext(UINT nSocketPort, int nSocketType, long lEvent, LPCTSTR lpszSocketAddress, int nFamily /*=AF_INET*/)
{
- DebugAssert(GetLayerState()==notsock);
+ DebugAssert((GetLayerState() == notsock) || (GetLayerState() == unconnected));
BOOL res = FALSE;
m_nFamily = nFamily;