]> granicus.if.org Git - neomutt/commit
Fix memleaks of saslconn on error paths
authorPeter Wu <peter@lekensteyn.nl>
Tue, 23 Oct 2018 10:29:26 +0000 (12:29 +0200)
committerRichard Russon <rich@flatcap.org>
Mon, 26 Nov 2018 18:27:21 +0000 (18:27 +0000)
commit9f408a6dbd4bf1c374d4963adb75810dc8ef76b7
tree2c51a43db9da6d228c398e290290853684b058a1
parent2893bc652055b00eb963f942d2556f9c195a8a70
Fix memleaks of saslconn on error paths

If mutt_sasl_client_new returns an error, the callers would ignore the
allocated saslconn resource from sasl_client_new. Be sure to release
these with sasl_dispose as documented in sasl.h. Likewise, let callers
(POP/IMAP) dispose the resource on their error paths. SMTP was already
taken care of. Found with LeakSanitizer in IMAP.
conn/sasl.c
imap/auth_sasl.c
pop/pop_auth.c