Bug 172388 - mhshow crashes on empty Content-Type
Summary: mhshow crashes on empty Content-Type
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Fedora
Classification: Fedora
Component: nmh
Version: 4
Hardware: i386
OS: Linux
medium
medium
Target Milestone: ---
Assignee: Josh Bressers
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2005-11-03 17:36 UTC by Joel Uckelman
Modified: 2007-11-30 22:11 UTC (History)
1 user (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2005-11-03 19:38:43 UTC
Type: ---
Embargoed:


Attachments (Terms of Use)
show crash output (1.94 KB, text/plain)
2005-11-03 17:43 UTC, Joel Uckelman
no flags Details
sample crash-causing message (620 bytes, text/plain)
2005-11-03 17:44 UTC, Joel Uckelman
no flags Details
Fix for this issue (463 bytes, patch)
2005-11-03 19:37 UTC, Josh Bressers
no flags Details | Diff

Description Joel Uckelman 2005-11-03 17:36:53 UTC
From Bugzilla Helper:
User-Agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.7.12) Gecko/20050920 Firefox/1.0.7

Description of problem:
When a multipart/mixed message has a part with an empty Content-Type, show crashes , apparently due to some memory being double-freed.

Version-Release number of selected component (if applicable):
nmh-1.1-9.fc4

How reproducible:
Always

Steps to Reproduce:
1. Put the example message in a folder.
2. show it.

Actual Results:  show crashes

Expected Results:  show should do something graceful, like assume that the faulty part is text/plain or notify the user that the part is being skipped.

Additional info:

Comment 1 Joel Uckelman 2005-11-03 17:43:07 UTC
Created attachment 120694 [details]
show crash output

Comment 2 Joel Uckelman 2005-11-03 17:44:15 UTC
Created attachment 120695 [details]
sample crash-causing message

Comment 3 Joel Uckelman 2005-11-03 17:50:53 UTC
Incidentally, leaving a Content-Type empty violates RFC 1521. Whatever email
client which is generating these is seriously broken.


Comment 4 Josh Bressers 2005-11-03 19:37:01 UTC
Created attachment 120701 [details]
Fix for this issue

The problem here is that when something goes wrong during mime processing, nmh
will try to close a file stream twice.	This patch removes the spurious
fclose().

Comment 5 Josh Bressers 2005-11-03 19:38:43 UTC
This issue is fixed in nmh-1.1-10.fc3, nmh-1.1-10.fc4 and nmh-1.1-10.fc5.


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