opensubscriber
   Find in this group all groups
 
Unknown more information…

b : bbdb-info@lists.sourceforge.net 18 July 2012 • 12:22AM -0400

bbdb-canonicalize-mail-function & anti-spam
by Sam Steingold

REPLY TO AUTHOR
 
REPLY TO GROUP




Some people use junk addresses, e.g., today in comp.lang.lisp there is a
message:

From: David Hodge <nospam@spam...>

Obviously, I don't want to put something like that into bbdb, so I would
like to create a record for David Hodge without any e-mail addresses.

I thought that bbdb-canonicalize-mail-function would do the job by
returning nil or "" for bad e-mail addresses, and it worked for quite
some time (it returned nil).

Now I am getting this (on entering the newsgroup):

Debugger entered--Lisp error: (wrong-type-argument char-or-string-p nil)
  bbdb-message-search("David Hodge" nil)
  gnus-user-format-function-b([47041 "Re: Interest in a Common Lisp library for Bayesian Network inference?" "David Hodge <nospam@spam...>" "Tue, 17 Jul 2012 08:09:05 +0800" "<87fw8rqme6.fsf@hodg...>" "<20760e57-a531-4356-baa0-f8e97672a28d@goog...>" 2066 18 "mx04.eternal-september.org comp.lang.lisp:47041" nil])
  (format "%c%4s: %s%-20s %s%c" gnus-tmp-opening-bracket gnus-tmp-lines (gnus-user-format-function-b gnus-tmp-header) (let* ((val (eval (let ((val ...)) (if (> ... 20) (if ... ... ...) val)))) (need (- 20 (string-width val)))) (if (> need 0) (concat nil val (make-string need 32)) val)) (gnus-date-iso8601 (mail-header-date gnus-tmp-header)) gnus-tmp-closing-bracket)
....

when I make bbdb-canonicalize-mail-function return "" instead of nil, I get

Debugger entered--Lisp error: (error "mail-extr returned \"\" as mail")
  signal(error ("mail-extr returned \"\" as mail"))
  error("mail-extr returned \"\" as mail")
  bbdb-annotate-message(("David Hodge" "" "From" sender gnus) bbdb-prompt-for-create)
  byte-code("\304=\203


------------------------------------------------------------------------------
Live Security Virtual Conference
Exclusive live event will cover all the ways today's security and
threat landscape has changed and how IT managers can respond. Discussions
will include endpoint security, mobile security and the latest in malware
threats. http://www.accelacomm.com/jaw/sfrnl04242012/114/50122263/
_______________________________________________
bbdb-info@list...
https://lists.sourceforge.net/lists/listinfo/bbdb-info
BBDB Home Page: http://bbdb.sourceforge.net/

Bookmark with:

Delicious   Digg   reddit   Facebook   StumbleUpon

Related Messages

opensubscriber is not affiliated with the authors of this message nor responsible for its content.