1
0
mirror of git://git.gnupg.org/gnupg.git synced 2024-12-31 11:41:32 +01:00

(read_passphrase_from_fd): Fixed memory leak.

Noted by Andrei Darashenka.
This commit is contained in:
Werner Koch 2004-12-13 08:04:52 +00:00
parent e4280026f4
commit 1037420b76
2 changed files with 9 additions and 1 deletions

View File

@ -1,3 +1,8 @@
2004-12-13 Werner Koch <wk@g10code.com>
* passphrase.c (read_passphrase_from_fd): Fixed memory leak.
Noted by Andrei Darashenka.
2004-12-11 David Shaw <dshaw@jabberwocky.com>
* keyserver.c (parse_preferred_keyserver): Force preferred

View File

@ -173,7 +173,10 @@ read_passphrase_from_fd( int fd )
len += 100;
pw = m_alloc_secure( len );
if( pw2 )
memcpy(pw, pw2, i );
{
memcpy(pw, pw2, i );
m_free (pw2);
}
else
i=0;
}