]> git.ipfire.org Git - thirdparty/libarchive.git/commit
Fix memory leak from passphrase callback 1378/head
authorStefan Baranoff <stefan.baranoff@trinitycyber.com>
Tue, 19 May 2020 00:57:14 +0000 (00:57 +0000)
committerStefan Baranoff <stefan.baranoff@trinitycyber.com>
Tue, 19 May 2020 01:03:23 +0000 (01:03 +0000)
commit35997ddf613702cfef0b026c6a4987dd68918897
tree75dac1e46e167400183fcb3bc873b09705d436c7
parent00d2d4be6a6eacb271d5e55c9d5da182a31f87b2
Fix memory leak from passphrase callback

There is a bug in the linked list implementation for passphrases. The insert to
head function does not account for the tail==head case and causes a leak. The
first entry into the list is lost when the second entry is added. The second
and beyond entries are are released properly, but the first is lost entirely.
libarchive/archive_read_add_passphrase.c