if(outer_p && msg->hdrs && ! msg->hdrs->done_p) { MimeMessage_parse_line("\n", 1, obj); }
MimeMessage_parse_eof (MimeObject *obj, PRBool abort_p){  int status;  PRBool outer_p;  MimeMessage *msg = (MimeMessage *)obj;  if (obj->closed_p) return 0;    /* Run parent method first, to flush out any buffered data. */  status = ((MimeObjectClass*)&MIME_SUPERCLASS)->parse_eof(obj, abort_p);  if (status < 0) return status;  outer_p = !obj->headers;	/* is this the outermost message? */  // Once we get to the end of parsing the message, we will notify  // the emitter that we are done the the body.  // Mark the end of the mail body if we are actually emitting the  // body of the message (i.e. not Header ONLY)  if (outer_p && obj->options && obj->options->write_html_p)  {	  if (obj->options->generate_footer_html_fn)	  {		  mime_stream_data *msd = 			  (mime_stream_data *) obj->options->stream_closure;		  if (msd)		  {			  char *html = obj->options->generate_footer_html_fn				  (msd->orig_url_name, obj->options->html_closure, msg->hdrs);			  if (html)			  {				  int lstatus = MimeObject_write(obj, html,												 strlen(html),												 PR_FALSE);				  PR_Free(html);				  if (lstatus < 0) return lstatus;			  }		  }	  }	  if ((!obj->options->part_to_load  || obj->options->format_out == nsMimeOutput::nsMimeMessageBodyDisplay) && 		  obj->options->headers != MimeHeadersOnly)		  mimeEmitterEndBody(obj->options);  }#ifdef MIME_DRAFTS  if ( obj->options &&	   obj->options->decompose_file_p &&	   obj->options->done_parsing_outer_headers &&	   ! obj->options->is_multipart_msg &&	   ! mime_typep(obj, (MimeObjectClass*) &mimeEncryptedClass) &&	   obj->options->decompose_file_close_fn ) {	status = obj->options->decompose_file_close_fn (											   obj->options->stream_closure );	if ( status < 0 ) return status;  }#endif /* MIME_DRAFTS */  /* Put out a separator after every message/rfc822 object. */  if (!abort_p && !outer_p)	{	  status = MimeObject_write_separator(obj);	  if (status < 0) return status;	}  return 0;}