summaryrefslogtreecommitdiff
path: root/alot/account.py
diff options
context:
space:
mode:
Diffstat (limited to 'alot/account.py')
-rw-r--r--alot/account.py3
1 files changed, 2 insertions, 1 deletions
diff --git a/alot/account.py b/alot/account.py
index 0404aa82..6eb9f099 100644
--- a/alot/account.py
+++ b/alot/account.py
@@ -140,7 +140,8 @@ class SendmailAccount(Account):
def send_mail(self, mail):
mail['Date'] = email.utils.formatdate(time.time(), True)
- out, err = helper.pipe_to_command(self.cmd, mail.as_string())
+ cmdlist = shlex.split(self.cmd.encode('utf-8', errors='ignore'))
+ out, err, retval = helper.call_cmd(cmdlist, stdin=mail.as_string())
if err:
return err + '. sendmail_cmd set to: %s' % self.cmd
self.store_sent_mail(mail)