On 020112, at 17:58:56, Roman Neuhauser wrote > ... I reported problems with mailcap handlers for tar.(gz|bz2) > files. ... I failed to get mutt recognize a file by its extension > no matter where I put the ext -> MIME type mapping > > ... the only place where the code mentions mime.types is > check_mime_type() in sendlib.c, however. Plus, it looks like this > function is only called when you *compose* a message ....
True, mutt only uses mime.types when composing a message, to set the content-type header for attachments based on file extension. > So... could someone point me to the function which mutt uses to > determine the MIME type of the attachments when you view a > message? When viewing a message, mutt uses the content-type header to determine the MIME type (and then mailcap to determine what to do with that type). It's up to the sending MUA to set the content-type header. It is possible to invoke a filter via a mailcap entry to try to guess the MIME type. For an example, see Dave Pearson's mutt.octet.filter (http://www.davep.org/mutt). -- David Ellement