Function: spam-bsfilter-register-with-bsfilter
spam-bsfilter-register-with-bsfilter is a byte-compiled function
defined in spam.el.gz.
Signature
(spam-bsfilter-register-with-bsfilter ARTICLES SPAM &optional UNREGISTER)
Documentation
Register an article, given as a string, as spam or non-spam.
Source Code
;; Defined in /usr/src/emacs/lisp/gnus/spam.el.gz
(defun spam-bsfilter-register-with-bsfilter (articles
spam
&optional unregister)
"Register an article, given as a string, as spam or non-spam."
(dolist (article articles)
(let ((article-string (spam-get-article-as-string article))
(switch (if unregister
(if spam
spam-bsfilter-spam-strong-switch
spam-bsfilter-ham-strong-switch)
(if spam
spam-bsfilter-spam-switch
spam-bsfilter-ham-switch))))
(when (stringp article-string)
(with-temp-buffer
(insert article-string)
(apply #'call-process-region
(point-min) (point-max)
spam-bsfilter-program
nil nil nil switch
"--update"
(when spam-bsfilter-database-directory
(list "--homedir"
spam-bsfilter-database-directory))))))))