Thanks for maintaining mimemail. It made life much easier sending email with attachments.

In one case, mimemail was not working for me. My apache error log showed: "exim abandoned: unknown, malformed, or incomplete option -f" (exim is the mail daemon on this server).

In my code I am not setting a Return-path header in the email I am sending. Despite this, I found that mimemail is trying to pass the -f flag to sendmail, and mail was not coming through.

Further investigation showed that mimemail's $return_path variable was "" (empty string), so that's why sendmail was reporting invalid parameters.

I fixed by changing if test from isset($return_path) to !empty($return_path). Patch attached.

Comments

sgabe’s picture

Title: sendmail invoked with invalid parameters causing error, send fails » Sendmail invoked with empty Return-Path
Status: Active » Fixed
StatusFileSize
new646 bytes
new570 bytes

First we need to check if the Return-Path is set and then if it is empty. The attached patches have been committed to both branches.

babbage’s picture

Excellent. Will be good to see a stable release with these fixes in it, but until then I've moved to -dev, albeit somewhat reluctantly.

Status: Fixed » Closed (fixed)

Automatically closed -- issue fixed for 2 weeks with no activity.