Subject: Re: bug#20211: 24.4; sendmail.el

From: Richard Ryniker <[email-masked]>
Date: Sat, 28 Mar 2015 09:51:53 -0400

Your strategy is better.  I focused too closely on simple avoidance of
the fault.  In fact, I believe the test you want is already present in
the previous two lines.  Tberefore, I think this does what you suggest:

*** 1302,1308 ****
        (if (and (bufferp errbuf)
                 (not error))
            (kill-buffer errbuf)
!         (switch-to-buffer-other-window errbuf)))))
  
  (autoload 'rmail-output-to-rmail-buffer "rmailout")
  
--- 1305,1312 ----
        (if (and (bufferp errbuf)
                 (not error))
            (kill-buffer errbuf)
!         (if (bufferp errbuf)
! 	    (switch-to-buffer-other-window errbuf))))))
  
  (autoload 'rmail-output-to-rmail-buffer "rmailout")