Hi,
I'm trying to get bbdb3 working and I came across a (potential)
bug. When I'm in the summary-buffer and I hit ':' to run
`bbdb-mua-display-sender', I get an error.

The relevant code is in "bbdb-mua.el" at `bbdb-update-records' line 206:
,----
|   (if (functionp update-p)                
|       (setq update-p (funcall update-p))) 
`----

If 'cl is loaded, `search' is a function, which gets called with no
arguments here:
,----
| search is a compiled Lisp function in `cl-seq.el'.
| 
| (search SEQ1 SEQ2 [KEYWORD VALUE]...)
`----

Here's the backtrace:

Debugger entered--Lisp error: (wrong-number-of-arguments (lambda (cl-seq1 
cl-seq2 &rest cl-keys) "Search for SEQ1 as a subsequence of SEQ2.
Return the index of the leftmost element of the first match found;
return nil if there are no matches.

Keywords supported:  :test :test-not :key :start1 :end1 :start2 :end2 :from-end

(fn SEQ1 SEQ2 [KEYWORD VALUE]...)" (cl-parsing-keywords (:test :test-not :key 
:from-end (:start1 0) :end1 (:start2 0) :end2) nil (or cl-end1 (setq cl-end1 
(length cl-seq1))) (or cl-end2 (setq cl-end2 (length cl-seq2))) (if (>= 
cl-start1 cl-end1) (if cl-from-end cl-end2 cl-start2) (let* ((cl-len (- cl-end1 
cl-start1)) (cl-first (cl-check-key (elt cl-seq1 cl-start1))) (cl-if nil) 
cl-pos) (setq cl-end2 (- cl-end2 (1- cl-len))) (while (and (< cl-start2 
cl-end2) (setq cl-pos (cl-position cl-first cl-seq2 cl-start2 cl-end2 
cl-from-end)) (apply (quote mismatch) cl-seq1 cl-seq2 :start1 (1+ cl-start1) 
:end1 cl-end1 :start2 (1+ cl-pos) :end2 (+ cl-pos cl-len) :from-end nil 
cl-keys)) (if cl-from-end (setq cl-end2 cl-pos) (setq cl-start2 (1+ cl-pos)))) 
(and (< cl-start2 cl-end2) cl-pos))))) 0)
  search()
  funcall(search)
  (setq update-p (funcall update-p))
  (if (functionp update-p) (setq update-p (funcall update-p)))
  bbdb-update-records(nil search nil)
  (cond ((eq mua (quote vm)) (vm-select-folder-buffer) 
(vm-check-for-killed-summary) (vm-error-if-folder-empty) (let 
((enable-local-variables t)) (bbdb-update-records (bbdb-get-address-components 
header-class) update-p (car vm-message-pointer)))) ((eq mua (quote gnus)) 
(bbdb-update-records (bbdb-get-address-components header-class) update-p 
(bbdb-message-header "Message-ID"))) ((eq mua (quote mh)) (if mh-show-buffer 
(set-buffer mh-show-buffer)) (bbdb-update-records (bbdb-get-address-components 
header-class) update-p (bbdb-message-header "Message-ID"))) ((eq mua (quote 
rmail)) (if (and (boundp (quote rmail-buffer)) rmail-buffer) (set-buffer 
rmail-buffer) (error "Not in an rmail buffer")) (when rmail-current-message 
(bbdb-update-records (bbdb-get-address-components header-class) update-p 
(bbdb-message-header "Message-ID")))) ((member mua (quote (message mail))) 
(bbdb-update-records (bbdb-get-address-components header-class) update-p)))
  (let ((mua (bbdb-mua))) (cond ((eq mua (quote vm)) (vm-select-folder-buffer) 
(vm-check-for-killed-summary) (vm-error-if-folder-empty) (let 
((enable-local-variables t)) (bbdb-update-records (bbdb-get-address-components 
header-class) update-p (car vm-message-pointer)))) ((eq mua (quote gnus)) 
(bbdb-update-records (bbdb-get-address-components header-class) update-p 
(bbdb-message-header "Message-ID"))) ((eq mua (quote mh)) (if mh-show-buffer 
(set-buffer mh-show-buffer)) (bbdb-update-records (bbdb-get-address-components 
header-class) update-p (bbdb-message-header "Message-ID"))) ((eq mua (quote 
rmail)) (if (and (boundp (quote rmail-buffer)) rmail-buffer) (set-buffer 
rmail-buffer) (error "Not in an rmail buffer")) (when rmail-current-message 
(bbdb-update-records (bbdb-get-address-components header-class) update-p 
(bbdb-message-header "Message-ID")))) ((member mua (quote (message mail))) 
(bbdb-update-records (bbdb-get-address-components header-class) update-p))))
  bbdb-mua-update-records(sender search)
  (let ((records (bbdb-mua-update-records header-class update-p))) (if records 
(bbdb-display-records-internal records)) records)
  (save-current-buffer (bbdb-mua-update-mua) (let ((records 
(bbdb-mua-update-records header-class update-p))) (if records 
(bbdb-display-records-internal records)) records))
  bbdb-mua-display-records(sender search)
  bbdb-mua-display-sender(search)
  call-interactively(bbdb-mua-display-sender nil nil)

When I prefix `bbdb-mua-display-sender', it gets called with 'query
instead of 'search and appears to work (ie no errors).


-- 
Philipp Haselwarter
------------------------------------------------------------------------------
Learn how Oracle Real Application Clusters (RAC) One Node allows customers
to consolidate database storage, standardize their database environment, and, 
should the need arise, upgrade to a full multi-node Oracle RAC database 
without downtime or disruption
http://p.sf.net/sfu/oracle-sfdevnl
_______________________________________________
bbdb-info@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/bbdb-info
BBDB Home Page: http://bbdb.sourceforge.net/

Reply via email to