Fixed bug #13701: @ini_set() works only on windows, on some unices it could render...
authorChristian Kuhn <lolli@schwarzbu.ch>
Mon, 31 May 2010 10:36:00 +0000 (10:36 +0000)
committerChristian Kuhn <lolli@schwarzbu.ch>
Mon, 31 May 2010 10:36:00 +0000 (10:36 +0000)
git-svn-id: https://svn.typo3.org/TYPO3v4/Core/trunk@7787 709f56b5-9817-0410-a4d7-c38de5d9e867

ChangeLog
t3lib/class.t3lib_htmlmail.php

index ac13f74..f2f6ad6 100755 (executable)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,7 @@
+2010-05-31  Christian Kuhn  <lolli@schwarzbu.ch>
+
+       * Fixed bug #13701: @ini_set() works only on windows, on some unices it could render the function unusable (Thanks to Stephan Seitz)
+
 2010-05-31  Steffen Kamper  <info@sk-typo3.de>
 
        * Fixed bug #14530: Missing icons in new BE skin (sprites) v6
index 21b8a54..a8eab3b 100644 (file)
@@ -725,8 +725,8 @@ class t3lib_htmlmail {
 
                        // On windows the -f flag is not used (specific for Sendmail and Postfix),
                        // but instead the php.ini parameter sendmail_from is used.
-               $returnPath = (strlen($this->returnPath) > 0) ? '-f ' . escapeshellarg($this->returnPath) : '';
-               if($this->returnPath) {
+               $returnPath = ($this->forceReturnPath && strlen($this->returnPath) > 0) ? '-f ' . escapeshellarg($this->returnPath) : '';
+               if (TYPO3_OS == 'WIN' && $this->returnPath) {
                        @ini_set('sendmail_from', t3lib_div::normalizeMailAddress($this->returnPath));
                }
                $recipient = t3lib_div::normalizeMailAddress($this->recipient);