termpty: fix possible issue when reading and the shell exited

This commit is contained in:
Boris Faure 2016-12-05 21:53:15 +01:00
parent 1f62588e97
commit 390e4193d0
1 changed files with 2 additions and 2 deletions

View File

@ -293,11 +293,11 @@ _cb_exe_exit(void *data,
ty->hand_exe_exit = NULL;
/* Read everything till the end */
do
res = ECORE_CALLBACK_PASS_ON;
while (ty->hand_fd && res != ECORE_CALLBACK_CANCEL)
{
res = _cb_fd_read(ty, ty->hand_fd);
}
while (res != ECORE_CALLBACK_CANCEL);
if (ty->hand_fd) ecore_main_fd_handler_del(ty->hand_fd);
ty->hand_fd = NULL;