diff --git a/libssh/keyfiles.c b/libssh/keyfiles.c index d7f5761e..147719c5 100644 --- a/libssh/keyfiles.c +++ b/libssh/keyfiles.c @@ -1280,9 +1280,9 @@ static int match_hashed_host(SSH_SESSION *session, const char *host, leave_function(); return 0; } - SAFE_FREE(source); hash = base64_to_bin(b64hash); + SAFE_FREE(source); if (hash == NULL) { buffer_free(salt); leave_function();