changeset 12107:5556c83c675a

(vc-register): Clean error message if no visited file.
author Karl Heuer <kwzh@gnu.org>
date Wed, 07 Jun 1995 20:50:55 +0000
parents 3ae851bcd773
children f75e47f673f4
files lisp/vc.el
diffstat 1 files changed, 2 insertions(+), 0 deletions(-) [+]
line wrap: on
line diff
--- a/lisp/vc.el	Wed Jun 07 20:48:53 1995 +0000
+++ b/lisp/vc.el	Wed Jun 07 20:50:55 1995 +0000
@@ -640,6 +640,8 @@
   "Register the current file into your version-control system."
   (interactive "P")
   (let ((master (vc-name buffer-file-name)))
+    (or buffer-file-name
+	(error "No visited file"))
     (and master (file-exists-p master)
 	 (error "This file is already registered"))
     (and master