Fix socket exceptions while querying the API

fixes #11224
This commit is contained in:
Michael Friedrich 2016-03-29 13:49:38 +02:00
parent eb0892273e
commit 5dd685cef9
1 changed files with 3 additions and 1 deletions

View File

@ -245,7 +245,9 @@ void TlsStream::OnEvent(int revents)
} }
if (m_Shutdown && !m_SendQ->IsDataAvailable()) { if (m_Shutdown && !m_SendQ->IsDataAvailable()) {
lock.unlock(); if (!success)
lock.unlock();
Close(); Close();
} }
} }