]> granicus.if.org Git - mutt/commitdiff
Undo Michaels "pgpsearchext" patch.
authorThomas Roessler <roessler@does-not-exist.org>
Sat, 8 Jan 2000 09:06:37 +0000 (09:06 +0000)
committerThomas Roessler <roessler@does-not-exist.org>
Sat, 8 Jan 2000 09:06:37 +0000 (09:06 +0000)
init.h
mutt.h
parse.c

diff --git a/init.h b/init.h
index 189d6e51b960d991db90a459446656bb92267671..318cb6f62cfdabaee3b95360e2e98dab91846061 100644 (file)
--- a/init.h
+++ b/init.h
@@ -1306,18 +1306,6 @@ struct option_t MuttVars[] = {
   { "forw_decrypt",    DT_SYN,  R_NONE, UL "forward_decrypt", 0 },
   /*
   */
-  { "pgp_search_text", DT_BOOL, R_NONE, OPTPGPSEARCHTEXT, 0 },
-  /*
-  ** .pp
-  ** Controls whether Mutt will search text/plain messages for old style
-  ** PGP message which are not properly labled using MIME header fields.
-  ** If the first non-blank line in a message contains "-----BEGIN PGP"
-  ** it will be assumed that it is an aplication/pgp content-type.
-  ** NOTE: this option should only be used as a last resort when procmail
-  ** is not available on your system. See doc/PGP-notes.txt for the
-  ** recommended way to handle old-style messages.  Using this option may
-  ** lead to longer time required to parse your mailbox.
-  */
 #endif /* _PGPPATH */
   
 #ifdef USE_SSL
diff --git a/mutt.h b/mutt.h
index 710699218013ddab0abf56070eccd34787b843b7..9e03e71c7f42ff0b7de2230b8aeb8d18c53c3c0e 100644 (file)
--- a/mutt.h
+++ b/mutt.h
@@ -360,7 +360,6 @@ enum
   OPTPGPSTRICTENC,
   OPTFORWDECRYPT,
   OPTPGPSHOWUNUSABLE,
-  OPTPGPSEARCHTEXT,
 #endif
 
   /* pseudo options */
diff --git a/parse.c b/parse.c
index 52f9d970fa45558aaa772ebb696b6a2410e696ff..93b3854c2c6f4c14c23d2d56c949123992d23d8b 100644 (file)
--- a/parse.c
+++ b/parse.c
@@ -1266,50 +1266,6 @@ ENVELOPE *mutt_read_rfc822_header (FILE *f, HEADER *hdr, short user_hdrs,
       dprint(1,(debugfile,"read_rfc822_header(): no date found, using received time from msg separator\n"));
       hdr->date_sent = hdr->received;
     }
-
-#ifdef _PGPPATH
-    if (option (OPTPGPSEARCHTEXT) && hdr->content->type == TYPETEXT &&
-           !strcasecmp("plain",hdr->content->subtype))
-    {
-       char scratch[LONG_STRING];
-
-       /* continue reading until we hit the first line of text in the message.
-          we check here to see if this might be an old-style PGP message
-          which is not properly labeled */
-
-       /* save this location so we can return here */
-       loc = ftell (f);
-
-       while (fgets (scratch, sizeof (scratch), f) != NULL)
-       {
-           p = scratch;
-           SKIPWS (p);
-           if (*p != '\n')
-           {
-               /* we got a non-empty line, check it */
-               if (!strncmp ("-----BEGIN PGP", scratch, 14))
-               {
-                   /* yes, this looks like an old style pgp message, alter
-                      the apparent content-type so that we handle this
-                      corrrectly */
-                   hdr->content->type = TYPEAPPLICATION;
-                   FREE (&hdr->content->subtype);
-                   hdr->content->subtype = safe_strdup ("pgp");
-                   mutt_free_parameter (&hdr->content->parameter);
-                   mutt_set_parameter ("format", "text", &hdr->content->parameter);
-                   /* check to see what type of PGP message we have */
-                   mutt_set_parameter ("x-action",
-                           !strncmp (" SI", scratch + 14, 3) ? "sign" : "encrypt",
-                           &hdr->content->parameter);
-               }
-               break;
-           }
-       }
-
-       /* return to where we ended before */
-       fseek (f, loc, SEEK_SET);
-    }
-#endif /* _PGPPATH */
   }
 
   return (e);