Important update:
- Bug fix: Error when writing to closed socket
This commit is contained in:
@@ -1169,9 +1169,14 @@ bool CSelectableCore::Write( THandle * Handle )
|
||||
int BytesWritten = 0;
|
||||
|
||||
// Validate
|
||||
if (!Handle || (Handle->State == csNone) || (Handle->State == csFailed) || (Handle->State == csClosed))
|
||||
if (!Handle)
|
||||
return false;
|
||||
|
||||
// Is Handle open?
|
||||
if ((Handle->State == csNone) || (Handle->State == csFailed) || (Handle->State == csClosed))
|
||||
{
|
||||
if (Handle->AutoManage)
|
||||
// May it be opened?
|
||||
if (Handle && Handle->AutoManage)
|
||||
{
|
||||
// Check duration since last PortIn
|
||||
if (Timeout( Handle->ReopenStart, Handle->ReopenDelay ))
|
||||
|
||||
Reference in New Issue
Block a user