1
0
mirror of https://github.com/libssh2/libssh2.git synced 2025-11-23 01:22:37 +03:00

SCP: clean up failure treatment

When SCP send or recv fails, it gets a special message from the server
with a warning or error message included. We have no current API to
expose that message but the foundation is there. Removed unnecessary use
of session struct fields.
This commit is contained in:
Daniel Stenberg
2010-11-10 17:17:32 +01:00
parent 1d2a5b8456
commit 1c3e1c4d25
3 changed files with 40 additions and 55 deletions

View File

@@ -968,12 +968,6 @@ session_free(LIBSSH2_SESSION *session)
if (session->scpSend_command) {
LIBSSH2_FREE(session, session->scpSend_command);
}
if (session->scpRecv_err_msg) {
LIBSSH2_FREE(session, session->scpRecv_err_msg);
}
if (session->scpSend_err_msg) {
LIBSSH2_FREE(session, session->scpSend_err_msg);
}
/* Cleanup all remaining packets */
while ((pkg = _libssh2_list_first(&session->packets))) {