X-Git-Url: http://git.madism.org/?p=apps%2Fmadmutt.git;a=blobdiff_plain;f=pattern.c;h=c8dff191357eb263642ecf270b83f9c3f4f80324;hp=3233a9288ef670137bab14fbd7ac97059bac1e21;hb=7b392ef7b50798f9eb3e7c869e634c5fef0092d1;hpb=92f2fc3802e13a8eb0717123c588d855fa0de67f diff --git a/pattern.c b/pattern.c index 3233a92..c8dff19 100644 --- a/pattern.c +++ b/pattern.c @@ -133,9 +133,9 @@ msg_search (CONTEXT *ctx, pattern_t* pat, int msgno) p_clear(&s, 1); s.fpin = msg->fp; s.flags = M_CHARCONV; - mutt_mktemp (tempfile); - if ((s.fpout = safe_fopen (tempfile, "w+")) == NULL) { - mutt_perror (tempfile); + s.fpout = m_tempfile(tempfile, sizeof(tempfile), NONULL(Tempdir), NULL); + if (!s.fpout) { + mutt_error(_("Could not create temporary file")); return (0); }