Solves the problem described in:

http://sourceforge.net/tracker/index.php?func=detail&aid=827436&group_id=12883&atid=112883

--- modules/mime/smtp.tcl	2005/10/07 07:26:40	1.44
+++ modules/mime/smtp.tcl	2006/11/06 21:21:59	1.45
@@ -1,7 +1,7 @@
 # smtp.tcl - SMTP client
 #
 # Copyright (c) 1999-2000 Marshall T. Rose
-# Copyright (c) 2003-2005 Pat Thoyts
+# Copyright (c) 2003-2006 Pat Thoyts
 #
 # See the file "license.terms" for information on usage and redistribution
 # of this file, and for a DISCLAIMER OF ALL WARRANTIES.
@@ -32,7 +32,7 @@
 
 
 namespace eval ::smtp {
-    variable version 1.4.2
+    variable version 1.4.3
     variable trf 1
     variable smtp
     array set smtp { uid 0 }
@@ -1123,6 +1123,10 @@
 	    while {[regsub -all -- {([^\r])\n} $result "\\1\r\n" result]} {}
             regsub -all -- {\n\.}      $result "\n.."   result
 
+            # Fix for bug #827436 - mail data must end with CRLF.CRLF
+            if {[string compare [string index $result end] "\n"] != 0} {
+                append result "\r\n"
+            }
             set state(size) [string length $result]
             puts -nonewline $state(sd) $result
             set result ""
