From: Brendan Cully Date: Mon, 9 Apr 2007 16:09:59 +0000 (-0700) Subject: Null out idata->hcache when closing, and remove close from open failure (mx_close... X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=2ab1e77d2f6dd5600a4b4c70fc40f1a4f2e6c8f2;p=neomutt Null out idata->hcache when closing, and remove close from open failure (mx_close will handle it). --- diff --git a/imap/imap.c b/imap/imap.c index 406221f30..c68f361eb 100644 --- a/imap/imap.c +++ b/imap/imap.c @@ -757,9 +757,6 @@ int imap_open_mailbox (CONTEXT* ctx) return 0; fail: -#ifdef USE_HCACHE - mutt_hcache_close (idata->hcache); -#endif if (idata->state == IMAP_SELECTED) idata->state = IMAP_AUTHENTICATED; fail_noidata: @@ -1324,6 +1321,7 @@ int imap_close_mailbox (CONTEXT* ctx) #ifdef USE_HCACHE mutt_hcache_close (idata->hcache); + idata->hcache = NULL; #endif mutt_bcache_close (&idata->bcache);