X-Git-Url: http://cgit.sxemacs.org/?a=blobdiff_plain;f=lisp%2Fhashcash.el;h=7382345dfe2c8ad58c466c278aa48e181dd95c2c;hb=1c5780ce5e6746957e3af0e2956f552b9f6fa23a;hp=d4d556af46eae45a4712d2175a7bf2067eeb431a;hpb=0b1507e0575a53f3ea410aafcc7b8fcd5bfdbf3c;p=gnus diff --git a/lisp/hashcash.el b/lisp/hashcash.el index d4d556af4..7382345df 100644 --- a/lisp/hashcash.el +++ b/lisp/hashcash.el @@ -238,15 +238,16 @@ Only start calculation. Results are inserted when ready." (hashcash-insert-payment-async-2 ,(current-buffer) process payment))))) (defun hashcash-insert-payment-async-2 (buffer process pay) - (with-current-buffer buffer - (save-excursion - (save-restriction - (setq hashcash-process-alist (delq - (assq process hashcash-process-alist) - hashcash-process-alist)) - (message-goto-eoh) - (when pay - (insert-before-markers "X-Hashcash: " pay)))))) + (when (buffer-live-p buffer) + (with-current-buffer buffer + (save-excursion + (save-restriction + (setq hashcash-process-alist (delq + (assq process hashcash-process-alist) + hashcash-process-alist)) + (message-goto-eoh) + (when pay + (insert-before-markers "X-Hashcash: " pay))))))) (defun hashcash-cancel-async (&optional buffer) "Delete any hashcash processes associated with BUFFER.