client/ClientRead: call Break() before Close()

Referencing the attribute "partition" is illegal after Close(),
because Close() deletes "this".
This commit is contained in:
Max Kellermann
2016-07-07 13:52:33 +02:00
parent b46cf57d98
commit e6389ff5a1
2 changed files with 2 additions and 2 deletions

View File

@@ -52,8 +52,8 @@ Client::OnSocketInput(void *data, size_t length)
break;
case CommandResult::KILL:
Close();
partition.instance.event_loop->Break();
Close();
return InputResult::CLOSED;
case CommandResult::FINISH: