X-Git-Url: http://git.madism.org/?p=apps%2Fmadmutt.git;a=blobdiff_plain;f=pattern.c;h=9839aa7a7dcd047ec18119fa45bc09bc6329ee3e;hp=594beda68fc52477c1cd86291a88483a185945a3;hb=6f12fb83ad1a93ca98c507325fdd70db2e36065f;hpb=c76ab67f3430e67b14b381bc1e3a23a14a4053b8 diff --git a/pattern.c b/pattern.c index 594beda..9839aa7 100644 --- a/pattern.c +++ b/pattern.c @@ -10,7 +10,6 @@ #include #include -#include #include #include #include @@ -18,6 +17,7 @@ #include "pattern.h" #include "alias.h" +#include "crypt.h" #include "handler.h" #include "keymap.h" #include "copy.h" @@ -141,7 +141,7 @@ msg_search (CONTEXT *ctx, pattern_t* pat, int msgno) p_clear(&s, 1); s.fpin = msg->fp; s.flags = M_CHARCONV; - s.fpout = m_tempfile(tempfile, sizeof(tempfile), NONULL(Tempdir), NULL); + s.fpout = m_tempfile(tempfile, sizeof(tempfile), NONULL(MCore.tmpdir), NULL); if (!s.fpout) { mutt_error(_("Could not create temporary file")); return (0); @@ -152,17 +152,6 @@ msg_search (CONTEXT *ctx, pattern_t* pat, int msgno) if (pat->op != M_HEADER) { mutt_parse_mime_message (ctx, h); - - if ((h->security & ENCRYPT) && !crypt_valid_passphrase (h->security)) - { - mx_close_message (&msg); - if (fp) { - m_fclose(&fp); - unlink (tempfile); - } - return (0); - } - fseeko (msg->fp, h->offset, 0); mutt_body_handler (h->content, &s); } @@ -1125,7 +1114,7 @@ void mutt_check_simple (char *s, ssize_t len, const char *simple) } } -int mutt_pattern_func (int op, char *prompt) +int mutt_pattern_func (int op, const char *prompt) { pattern_t *pat; char buf[LONG_STRING] = "", *simple, error[STRING];