Mimeparser rewrite; fix bug detecting trailing MIME-Boundary