Skip to content
This repository has been archived by the owner on Jan 30, 2020. It is now read-only.

Commit

Permalink
[zendframework/zendframework#3261] use -f switch instead of -r
Browse files Browse the repository at this point in the history
- "-r" is evidently a deprecated/obsolete synonym for "-f", and not
  present on current versions of sendmail (though still present on many
  clones, including postfix, exim, and qmail)
  - updated tests to refer to "-f" instead of "-r"
  • Loading branch information
weierophinney committed Jan 2, 2013
1 parent 2d445db commit c2cf931
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion src/Transport/Sendmail.php
Original file line number Diff line number Diff line change
Expand Up @@ -252,7 +252,7 @@ protected function prepareParameters(Mail\Message $message)
if (count($from)) {
$from->rewind();
$sender = $from->current();
$parameters .= ' -r ' . $sender->getEmail();
$parameters .= ' -f ' . $sender->getEmail();
return $parameters;
}

Expand Down
2 changes: 1 addition & 1 deletion test/Transport/SendmailTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -89,7 +89,7 @@ public function testReceivesMailArtifactsOnUnixSystems()
$this->assertContains("From: zf-devteam@zend.com,\r\n Matthew <matthew@zend.com>\r\n", $this->additional_headers);
$this->assertContains("X-Foo-Bar: Matthew\r\n", $this->additional_headers);
$this->assertContains("Sender: Ralph Schindler <ralph.schindler@zend.com>\r\n", $this->additional_headers);
$this->assertEquals('-R hdrs -r ralph.schindler@zend.com', $this->additional_parameters);
$this->assertEquals('-R hdrs -f ralph.schindler@zend.com', $this->additional_parameters);
}

public function testReceivesMailArtifactsOnWindowsSystems()
Expand Down

0 comments on commit c2cf931

Please sign in to comment.