X-Git-Url: http://git.madism.org/?p=apps%2Fmadmutt.git;a=blobdiff_plain;f=parse.c;h=6a076540807c683bcfc9944b6df2279e17c4ae72;hp=b8fa55ff88f926a0be197d9fcbd5dd6e8b678d76;hb=be99cd72fc79e2f10aec2b06d62abb16c16aa34d;hpb=a9a13ba67dbdce47d4d686a787306474b49d1ef5 diff --git a/parse.c b/parse.c index b8fa55f..6a07654 100644 --- a/parse.c +++ b/parse.c @@ -1057,6 +1057,15 @@ int mutt_parse_rfc822_line (ENVELOPE *e, HEADER *hdr, char *line, char *p, short if (!ascii_strcasecmp ("rom", line + 1)) { e->from = rfc822_parse_adrlist (e->from, p); + /* don't leave from info NULL if there's an invalid address (or + * whatever) in From: field; mutt would just display it as empty + * and mark mail/(esp.) news article as your own. aaargh! this + * bothered me for _years_ */ + if (!e->from) + { + e->from = rfc822_new_address (); + e->from->personal = safe_strdup (line+6); + } matched = 1; } #ifdef USE_NNTP