Bug 770782 - mutt does not handle attachments properly with an existing mailcap file
mutt does not handle attachments properly with an existing mailcap file
Status: CLOSED DUPLICATE of bug 653249
Product: Fedora
Classification: Fedora
Component: mailcap (Show other bugs)
Unspecified Unspecified
unspecified Severity unspecified
: ---
: ---
Assigned To: Miroslav Lichvar
Fedora Extras Quality Assurance
Depends On:
  Show dependency treegraph
Reported: 2011-12-28 23:30 EST by Michal Jaegermann
Modified: 2012-01-05 14:12 EST (History)
5 users (show)

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Last Closed: 2012-01-05 13:21:53 EST
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---

Attachments (Terms of Use)

  None (edit)
Description Michal Jaegermann 2011-12-28 23:30:53 EST
Description of problem:

Assume that one of mail message attachments is a some_picture.jpg JPEG file and mutt read this message and that we are in attachment menu.  Putting a cursor on 'some_picture.jpg' entry and hitting return results in an alert with:

No images found in 'file:///tmp/some_picture.jpg'.

Closer check reveals that mutt does write /tmp/some_picture.jpg but with

image/*; /usr/bin/xdg-open %s

entry in /etc/mailcap fails to handle it.  This does work if /etc/mailcap line is replaced with

image/*; /usr/bin/xdg-open %s ; copiousoutput

The same goes if an attachment is of application/pdf type and the same cure applies.  I strongly suspect that this will be also the case with every MIME type where an external handler is required although I bumped into that with images and checked for PDF too but not for anything else.

Version-Release number of selected component (if applicable):

Additional info:
I know for sure that sometime in the past mutt in Fedora 14 did NOT require 'copiousoutput' and worked without that fine but I cannot tell now if this was the case with the latest F14 updates.  I can confirm, though, that
mutt- has not problems with "missing" 'copiousoutput'.  I cannot tell if this change was deliberate; I failed to find anything on this in ChangeLog.
Comment 1 Michal Jaegermann 2011-12-29 00:20:08 EST
Additional check reveal that these are entries with /usr/bin/xdg-open, or apparently some other intermediary shell script, which require 'copiousoutput'.
That means that with 'application/pdf' this does NOT work:

application/pdf; /usr/bin/xdg-open %s

but either of the following two (assuming evince installed):

application/pdf; evince %s
application/pdf; /usr/bin/xdg-open %s ; copiousoutput

is fine.

Hm, that likely means this this worked with mutt- just because
a corresponding mailcap entry was of a type 'application/pdf; evince %s'.
Comment 2 Honza Horak 2012-01-05 09:55:23 EST
Hi, I see the same behavior, but /etc/mailcap is a part of mailcap package, so re-assigning this bug to that one.
Comment 3 Ville Skyttä 2012-01-05 13:21:53 EST

*** This bug has been marked as a duplicate of bug 653249 ***

Note You need to log in before you can comment on or make changes to this bug.