mirror of
git://git.gnupg.org/gnupg.git
synced 2025-03-28 22:49:59 +01:00
* passphrase.c (agent_get_passphrase): Fix memory leak with symmetric
messages. Fix segfault with symmetric messages. Fix incorrect prompt with symmetric messages.
This commit is contained in:
parent
034bbc759f
commit
1dc153dfd2
@ -1,3 +1,9 @@
|
|||||||
|
2003-03-05 David Shaw <dshaw@jabberwocky.com>
|
||||||
|
|
||||||
|
* passphrase.c (agent_get_passphrase): Fix memory leak with
|
||||||
|
symmetric messages. Fix segfault with symmetric messages. Fix
|
||||||
|
incorrect prompt with symmetric messages.
|
||||||
|
|
||||||
2003-03-04 David Shaw <dshaw@jabberwocky.com>
|
2003-03-04 David Shaw <dshaw@jabberwocky.com>
|
||||||
|
|
||||||
* options.skel: Add explantion and commented-out
|
* options.skel: Add explantion and commented-out
|
||||||
|
@ -614,9 +614,12 @@ agent_get_passphrase ( u32 *keyid, int mode, const char *tryagain_text )
|
|||||||
|
|
||||||
memset (fpr, 0, MAX_FINGERPRINT_LEN );
|
memset (fpr, 0, MAX_FINGERPRINT_LEN );
|
||||||
if( keyid && get_pubkey( pk, keyid ) )
|
if( keyid && get_pubkey( pk, keyid ) )
|
||||||
pk = NULL; /* oops: no key for some reason */
|
{
|
||||||
|
free_public_key( pk );
|
||||||
|
pk = NULL; /* oops: no key for some reason */
|
||||||
|
}
|
||||||
|
|
||||||
if ( !mode && pk )
|
if ( !mode && pk && keyid )
|
||||||
{
|
{
|
||||||
char *uid;
|
char *uid;
|
||||||
size_t uidlen;
|
size_t uidlen;
|
||||||
@ -658,10 +661,10 @@ agent_get_passphrase ( u32 *keyid, int mode, const char *tryagain_text )
|
|||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
else if (mode == 1 )
|
else if (mode == 2 )
|
||||||
atext = m_strdup ( _("Enter passphrase\n") );
|
|
||||||
else
|
|
||||||
atext = m_strdup ( _("Repeat passphrase\n") );
|
atext = m_strdup ( _("Repeat passphrase\n") );
|
||||||
|
else
|
||||||
|
atext = m_strdup ( _("Enter passphrase\n") );
|
||||||
|
|
||||||
if ( (fd = agent_open (&prot)) == -1 )
|
if ( (fd = agent_open (&prot)) == -1 )
|
||||||
goto failure;
|
goto failure;
|
||||||
|
Loading…
x
Reference in New Issue
Block a user