fix for extra trailing new lines on attachments

When sending ascii encoded attachments there is an extra newline appearing at the end of files.