Skip to content

Commit c8692f7

Browse files
kill child process after SSH connection failure
1 parent 735cd89 commit c8692f7

1 file changed

Lines changed: 2 additions & 0 deletions

File tree

apps/wolfsshd/wolfsshd.c

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1498,6 +1498,8 @@ static int SHELL_Subsystem(WOLFSSHD_CONNECTION* conn, WOLFSSH* ssh,
14981498
continue;
14991499
}
15001500
else if (rc != WS_WANT_READ) {
1501+
/* unexpected error, kill off child process */
1502+
kill(childPid, SIGKILL);
15011503
break;
15021504
}
15031505
}

0 commit comments

Comments
 (0)