Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

add check for channel closed error #710

Merged
merged 2 commits into from
Jun 17, 2024
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 3 additions & 1 deletion examples/scpclient/scpclient.c
Original file line number Diff line number Diff line change
Expand Up @@ -313,7 +313,9 @@ THREAD_RETURN WOLFSSH_THREAD scp_client(void* args)

ret = wolfSSH_shutdown(ssh);
/* do not continue on with shutdown process if peer already disconnected */
if (ret != WS_SOCKET_ERROR_E && wolfSSH_get_error(ssh) != WS_SOCKET_ERROR_E) {
if (ret != WS_CHANNEL_CLOSED && ret != WS_SOCKET_ERROR_E &&
ejohnstown marked this conversation as resolved.
Show resolved Hide resolved
wolfSSH_get_error(ssh) != WS_SOCKET_ERROR_E &&
wolfSSH_get_error(ssh) != WS_CHANNEL_CLOSED) {
if (ret != WS_SUCCESS) {
err_sys("Sending the shutdown messages failed.");
}
Expand Down
Loading