libssh: goto DISCONNECT state on error, not SSH_SESSION_FREE

... because otherwise not everything get closed down correctly.

Fixes #2708
Closes #2712
This commit is contained in:
Daniel Stenberg 2018-07-05 22:45:01 +02:00
parent 0d3eeaadb4
commit 03d884b7d8
No known key found for this signature in database
GPG Key ID: 5CC908FDB71E12C2
1 changed files with 1 additions and 1 deletions

View File

@ -429,7 +429,7 @@ cleanup:
}
#define MOVE_TO_ERROR_STATE(_r) { \
state(conn, SSH_SESSION_FREE); \
state(conn, SSH_SESSION_DISCONNECT); \
sshc->actualcode = _r; \
rc = SSH_ERROR; \
break; \