Exim abandoned: unknown, malformed, or incomplete option -s
Hi all, I am getting the following error in my ssh terminal when my script prompts an email to be sent:
exim abandoned: unknown, malformed, or incomplete option -s
My script is as follows:
any suggestions?
void send_alert(const std::string &subject, const std::string &text) {
start_sql("SELECT * FROM tconfig;");
run_sql();
std::string sender_addr = decode_str(sql_result("sender_addr"));
std::string alert_addr = decode_str(sql_result("alert_addr"));
end_sql();
std::string filename = tmpnam(NULL);
std::ofstream file(filename.c_str());
file << text;
file.close();
std::string cmd = "mail " + alert_addr + " -s '" + subject + "' < " + filename;
system(cmd.c_str());
}any suggestions?
-
Hello :) The "s" flag as you have used it is not valid. EX: # exim -s exim abandoned: unknown, malformed, or incomplete option -s
You should update the script so it uses a valid flag. Thank you.0
Please sign in to leave a comment.
Comments
1 comment