Ver Fonte

* Found my bug

Tyler Akins há 24 anos atrás
pai
commit
9798d0a2aa
1 ficheiros alterados com 2 adições e 1 exclusões
  1. 2 1
      functions/smtp.php

+ 2 - 1
functions/smtp.php

@@ -100,7 +100,8 @@
 	          $tmp = str_replace("\r\n", "\n", $tmp);
 	          $tmp = str_replace("\r", "\n", $tmp);
 	          $tmp = str_replace("\n", "\r\n", $tmp);
-		  $tmp .= "\r\n";
+		  if (feof($fp) && substr($tmp, -2) != "\r\n")
+		     $tmp .= "\r\n";
 		  fputs($fp, $tmp);
 		  $length += strlen($tmp);
 	       }