зеркало из https://github.com/github/putty.git
cmdgen: fix double-free on exit.
Freeing ssh1key->comment before calling freersakey() on the whole of ssh1key is redundant, and worse, because we also didn't null out the freed pointer, causes a double-free.
This commit is contained in:
Родитель
6dc8860f8a
Коммит
eec6666ff9
1
cmdgen.c
1
cmdgen.c
|
@ -1064,7 +1064,6 @@ int main(int argc, char **argv)
|
|||
}
|
||||
|
||||
if (ssh1key) {
|
||||
sfree(ssh1key->comment);
|
||||
freersakey(ssh1key);
|
||||
}
|
||||
if (ssh2key) {
|
||||
|
|
Загрузка…
Ссылка в новой задаче