1
0
mirror of git://git.gnupg.org/gnupg.git synced 2024-12-22 10:19:57 +01:00

Fixed invalid free.

This commit is contained in:
Ben Kibbey 2011-09-12 20:13:18 -04:00 committed by Werner Koch
parent 57ef0d6087
commit eb5709f554

View File

@ -311,9 +311,7 @@ agent_ask_new_passphrase (ctrl_t ctrl, const char *prompt,
unsigned char *buffer;
err = pinentry_loopback(ctrl, "NEW_PASSPHRASE", &buffer, &size, len);
if (err)
xfree(buffer);
else
if (!err)
{
buffer[size] = 0;
*r_passphrase = buffer;