Changeset 5045:29ceb4442588

Show
Ignore:
Timestamp:
2007-04-02 11:00:22 (22 months ago)
Author:
Brendan Cully <brendan@…>
Branch:
HEAD
Message:

Fix segfault in new mboxcache hcache check when create is 0

Files:
2 modified

Legend:

Unmodified
Added
Removed
  • ChangeLog

    r5043 r5045  
    1 2007-04-02 10:02 -0700  Brendan Cully  <brendan@kublai.com>  (becbad651ecc) 
     12007-04-02 10:48 -0700  Brendan Cully  <brendan@kublai.com>  (aa6f191cfa10) 
     2 
     3        * imap/command.c, imap/imap.c, imap/imap_private.h, imap/message.c: 
     4        Add create flag to imap_mboxcache_get 
     5 
     6        * imap/command.c, imap/imap.c: Push mbox cache header cache check 
     7        into imap_mboxcache_get 
    28 
    39        * imap/imap.c: Cache IMAP access checks 
  • imap/imap.c

    r5044 r5045  
    16171617    uidvalidity = mutt_hcache_fetch_raw (hc, "/UIDVALIDITY", imap_hcache_keylen); 
    16181618    uidnext = mutt_hcache_fetch_raw (hc, "/UIDNEXT", imap_hcache_keylen); 
     1619    mutt_hcache_close (hc); 
    16191620    if (uidvalidity) 
    16201621    { 
     1622      if (!status) 
     1623      { 
     1624        FREE (&uidvalidity); 
     1625        FREE (&uidnext); 
     1626        return imap_mboxcache_get (idata, mbox, 1); 
     1627      } 
    16211628      status->uidvalidity = *uidvalidity; 
    16221629      status->uidnext = uidnext ? *uidnext: 0; 
     
    16261633    FREE (&uidvalidity); 
    16271634    FREE (&uidnext); 
    1628     mutt_hcache_close (hc); 
    16291635  } 
    16301636#endif