diff options
author | Thomas Roessler <roessler@does-not-exist.org> | 1999-01-25 22:16:46 +0000 |
---|---|---|
committer | Thomas Roessler <roessler@does-not-exist.org> | 1999-01-25 22:16:46 +0000 |
commit | 3530aa43a4e2ad2fc20a011e421e11aedc892519 (patch) | |
tree | 591b061ffc2e95fd302cf8cd53f47913c922f8a4 /compose.c | |
parent | 757b3b6548d7a01a1a705b336815abe688d15f1b (diff) |
This may fix a core dump under certain circumstances. Can't check
this out since I don't get the segfault.
Diffstat (limited to 'compose.c')
-rw-r--r-- | compose.c | 13 |
1 files changed, 11 insertions, 2 deletions
@@ -775,9 +775,9 @@ int mutt_compose_menu (HEADER *msg, /* structure for new message */ s = b->filename; par = b->parameter; b->filename = NULL; b->parameter = NULL; - mutt_parse_content_type(buf, b); + mutt_parse_content_type (buf, b); - safe_free((void **) &b->filename); + safe_free ((void **) &b->filename); b->filename = s; if ((s = mutt_get_parameter("charset", b->parameter))) @@ -796,6 +796,15 @@ int mutt_compose_menu (HEADER *msg, /* structure for new message */ mutt_free_parameter(&b->parameter); b->parameter = par; + /* this may have been a "structured" message */ + if (b->parts) + mutt_free_body (&b->parts); + if (b->hdr) + { + b->hdr->content = NULL; + mutt_free_header (&b->hdr); + } + menu->redraw = REDRAW_CURRENT; } break; |