From 833eadc27c5d6c03425c7f3eddde43cec4a48251 Mon Sep 17 00:00:00 2001 From: Dave Love Date: Thu, 12 Nov 1998 15:54:40 +0000 Subject: [PATCH] 1998-11-09 Sam Steingold * browse-url.el (browse-url): handle the case when `browse-url-browser-function' is a lambda list. --- lisp/browse-url.el | 11 ++++++----- 1 file changed, 6 insertions(+), 5 deletions(-) diff --git a/lisp/browse-url.el b/lisp/browse-url.el index 3be0331196b..68f09f8440b 100644 --- a/lisp/browse-url.el +++ b/lisp/browse-url.el @@ -617,11 +617,12 @@ Prompts for a URL, defaulting to the URL at or before point. Variable `browse-url-browser-function' says which browser to use." (interactive (browse-url-interactive-arg "URL: ")) (let ((bf browse-url-browser-function) re) - (while (consp bf) - (setq re (car (car bf)) - bf (if (string-match re url) - (cdr (car bf)) ; The function - (cdr bf)))) ; More pairs + (unless (functionp bf) + (while (consp bf) + (setq re (car (car bf)) + bf (if (string-match re url) + (cdr (car bf)) ; The function + (cdr bf))))) ; More pairs (or bf (error "No browser in browse-url-browser-function matching URL %s" url)) (apply bf url args))) -- 2.39.2