diff --git a/mimemail.inc b/mimemail.inc
index 7ce2386..514a168 100644
--- a/mimemail.inc
+++ b/mimemail.inc
@@ -16,7 +16,7 @@
  */
 function mimemail_rfc_headers($headers) {
   $header = '';
-  $crlf = variable_get('mimemail_crlf', "\n");
+  $crlf = variable_get('mimemail_crlf', MAIL_LINE_ENDINGS);
   foreach ($headers as $key => $value) {
     $key = trim($key);
     // collapse spaces and get rid of newline characters
diff --git a/mimemail.module b/mimemail.module
index 26a8414..844dafc 100644
--- a/mimemail.module
+++ b/mimemail.module
@@ -347,9 +347,11 @@ function mimemail_mailengine($op, $message = array()) {
         }
       }
 
+      $crlf = variable_get('mimemail_crlf', MAIL_LINE_ENDINGS);
+
       $recipients = (!is_array($message['to'])) ? array($message['to']) : $message['to'];
       $subject = mime_header_encode($message['subject']);
-      $body = $message['body'];
+      $body = preg_replace('@\r?\n@', $crlf, $message['body']);
       $headers = mimemail_rfc_headers($message['headers']);
 
       $result = TRUE;
