The attached patch fixes a segmentation fault which would occur when
the operates without a Context (this happens, for instance, when you
can't connect to an IMAP folder).
--
http://www.guug.de/~roessler/
Index: imap/util.c
===================================================================
RCS file: /home/roessler/cvsroot/mutt/imap/util.c,v
retrieving revision 1.18
diff -u -p -u -r1.18 util.c
--- imap/util.c 2000/02/28 17:54:41 1.18
+++ imap/util.c 2000/03/01 11:56:53
@@ -375,12 +375,12 @@ int imap_wait_keepalive (pid_t pid)
void imap_allow_reopen (CONTEXT *ctx)
{
- if (ctx->magic == M_IMAP && CTX_DATA->selected_ctx == ctx)
+ if (ctx && ctx->magic == M_IMAP && CTX_DATA->selected_ctx == ctx)
CTX_DATA->reopen |= IMAP_REOPEN_ALLOW;
}
void imap_disallow_reopen (CONTEXT *ctx)
{
- if (ctx->magic == M_IMAP && CTX_DATA->selected_ctx == ctx)
+ if (ctx && ctx->magic == M_IMAP && CTX_DATA->selected_ctx == ctx)
CTX_DATA->reopen &= ~IMAP_REOPEN_ALLOW;
}
PGP signature