aboutsummaryrefslogtreecommitdiffstats
path: root/lisp/vc.el
diff options
context:
space:
mode:
authorKarl Heuer <[email protected]>1995-06-07 20:50:55 +0000
committerKarl Heuer <[email protected]>1995-06-07 20:50:55 +0000
commitf7aabd88d83b859f9236f4b3e324c87166740926 (patch)
tree2c99421b8ec4f728633ff11a985edc174fd83da9 /lisp/vc.el
parentc6431f12aaad67960924c20758e8810076c0e4d0 (diff)
(vc-register): Clean error message if no visited file.
Diffstat (limited to 'lisp/vc.el')
-rw-r--r--lisp/vc.el2
1 files changed, 2 insertions, 0 deletions
diff --git a/lisp/vc.el b/lisp/vc.el
index 54f71fb0d9..c68973505e 100644
--- a/lisp/vc.el
+++ b/lisp/vc.el
@@ -640,6 +640,8 @@ merge in the changes into your working copy."
"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