]> code.delx.au - gnu-emacs-elpa/commitdiff
Protect against front-end errors.
authorNikolaj Schumacher <git@nschum.de>
Tue, 17 Mar 2009 12:54:39 +0000 (13:54 +0100)
committerNikolaj Schumacher <git@nschum.de>
Fri, 20 Mar 2009 11:58:29 +0000 (12:58 +0100)
company.el

index 5ea09254d95827c3001470b6ca5b65ae5d76eb40..2859cb9a882141846e026131abe0cba97cc98a32 100644 (file)
 
 (defsubst company-call-frontends (command)
   (dolist (frontend company-frontends)
-    (funcall frontend command)))
+    (condition-case err
+        (funcall frontend command)
+      (error (error "Company: Front-end %s error \"%s\" on command %s"
+                    frontend (error-message-string err) command)))))
 
 (defsubst company-set-selection (selection &optional force-update)
   (setq selection (max 0 (min (1- (length company-candidates)) selection)))