Forwarding with attachments is only working correctly if either forwarding the complete original message as an attachment itself (Forward As Attachment) or resending the original message (Edit As New). The former may not be displayed correctly in receiving mail clients, while the latter doesn't really look like a forwarded message.
The attached patch is a compromise that changes the "Edit As New" method of forwarding to include the leading and trailing marks including a message header summery, just like the "In Body Text" forwarding method, and prefixing the subject line.
The patch is against IMP H5, specifically version 6.2.16.