1
0
mirror of https://git.libssh.org/projects/libssh.git synced 2025-11-29 01:03:57 +03:00

pki: Fix memory leak of blob on error

CID #1419377

Signed-off-by: Andreas Schneider <asn@cryptomilk.org>
Reviewed-by: Jakub Jelen <jjelen@redhat.com>
This commit is contained in:
Andreas Schneider
2020-02-12 09:41:11 +01:00
parent 875b2a5b59
commit 9fcb559301

View File

@@ -2293,6 +2293,7 @@ int ssh_pki_import_signature_blob(const ssh_string sig_blob,
rc = ssh_buffer_unpack(buf, "bd", &flags, &counter);
if (rc < 0) {
SSH_BUFFER_FREE(buf);
SSH_STRING_FREE(blob);
return SSH_ERROR;
}
}