kio: disconnect the slave and close the connection in case of error in the slave loop

this was done only when there was pool socket (when klauncher was handling
slaves) but it has to be done anyway to prevent more tasks (commands) from
being send after error occurs

Signed-off-by: Ivailo Monev <xakepa10@gmail.com>
This commit is contained in:
Ivailo Monev 2022-12-06 05:22:53 +02:00
parent bc067dbdfa
commit c1a17d5a30

View file

@ -307,6 +307,8 @@ void SlaveBase::dispatchLoop()
}
if (ret == -1) { // some error occurred, perhaps no more application
disconnectSlave();
closeConnection();
break;
}