From: André Spiegel Date: Fri, 22 Sep 2000 07:49:19 +0000 (+0000) Subject: (vc-switch-backend): Signal an error if the file is not registered X-Git-Tag: emacs-pretest-21.0.90~1429 X-Git-Url: http://git.eshelyaron.com/gitweb/?a=commitdiff_plain;h=e07adf40d3fedeb5e410a1085d7abdf7d9275204;p=emacs.git (vc-switch-backend): Signal an error if the file is not registered under the new backend. --- diff --git a/lisp/vc.el b/lisp/vc.el index b298831cb1b..4dba0fea2ae 100644 --- a/lisp/vc.el +++ b/lisp/vc.el @@ -2190,6 +2190,8 @@ VC's perspective on FILE, it does not register or unregister it." (list buffer-file-name (intern (upcase (read-string "Switch to backend: "))))) + (unless (vc-call-backend backend 'registered file) + (error "%s is not registered in %s" file backend)) (vc-file-clearprops file) (vc-file-setprop file 'vc-backend backend) (vc-resynch-buffer file t t))