GNU bug report logs - #18173
24.3; message-sendmail-extra-arguments not applied

Previous Next

Packages: gnus, emacs;

Reported by: Myles English <mylesenglish <at> gmail.com>

Date: Sat, 2 Aug 2014 15:10:02 UTC

Severity: normal

Tags: notabug, patch

Found in version 24.3

Done: Glenn Morris <rgm <at> gnu.org>

Bug is archived. No further changes may be made.

Full log


View this message in rfc822 format

From: Myles English <mylesenglish <at> gmail.com>
To: Glenn Morris <rgm <at> gnu.org>
Cc: 18173 <at> debbugs.gnu.org
Subject: bug#18173: 24.3; message-sendmail-extra-arguments not applied
Date: Sat, 04 Oct 2014 22:25:12 +0100
Glenn Morris writes:

> Sorry, I'm being dense, because I cannot see a bug here, or how your
> patch makes any difference to anything. Can you explain?

I can't reproduce this bug anymore (you can stop reading here).  I'll
explain what I thought the bug was for posterity.

With sendmail-program set to /usr/bin/msmtp.  Without the patch below,
msmtp finds its config file in the default location ~/.msmtprc .  It is
possible specify a different config file on the command line using the
-C option.  However, using this:

(setq message-sendmail-extra-arguments '("-C"
       "/home/myles/.config/msmtp/msmtprc"))

did not result in msmtp finding its config file.  The doc for
message-sendmail-extra-arguments says "Additional arguments to
`sendmail-program'".  The 'bug' was that the extra argument should be
applied but it is not.

After applying the patch below, the config file is found in the
non-default location.  The 'bug' is fixed because the extra argument is
applied.

I don't know why the patch works or much about elisp (I copied from
elsewhere in the source).

While debugging, message-sendmail-extra-arguments seemed to be something
other than a string, the patch below seamed to cause it to be string
consistently.

Myles

>> --- message.el
>> +++ message.el
>> @@ -4723,9 +4723,7 @@
>>  		(erase-buffer))))
>>  	  (let* ((default-directory "/")
>>  		 (coding-system-for-write message-send-coding-system)
>> -		 (cpr (apply
>> -		       'call-process-region
>> -		       (append
>> +		 (args (append
>>  			(list (point-min) (point-max) sendmail-program
>>  			      nil errbuf nil "-oi")
>>  			message-sendmail-extra-arguments
>> @@ -4745,7 +4743,8 @@
>>  			;; For a resend, include the specific addresses.
>>  			(if resend-to-addresses
>>  			    (list resend-to-addresses)
>> -			  '("-t"))))))
>> +			  '("-t"))))
>> +		 (cpr (apply 'call-process-region args)))
>>  	    (unless (or (null cpr) (and (numberp cpr) (zerop cpr)))
>>                (if errbuf (pop-to-buffer errbuf))
>>  	      (error "Sending...failed with exit value %d" cpr)))





This bug report was last modified 10 years and 229 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.