- (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-Payment: hashcash "
-;; (number-to-string (hashcash-version pay)) " "
-;; pay "\n")
- (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)))))))