# HG changeset patch # User Paul Eggert # Date 743921927 0 # Node ID 0e9960f5e99c8b12f6388bd36433cb95f42eaea3 # Parent cda282328afd33d13b7a6c03cd74127510998a27 (vc-mode-line): Set vc-mode to nil if FILE no longer is version-controlled. diff -r cda282328afd -r 0e9960f5e99c lisp/vc-hooks.el --- a/lisp/vc-hooks.el Thu Jul 29 04:50:27 1993 +0000 +++ b/lisp/vc-hooks.el Thu Jul 29 04:58:47 1993 +0000 @@ -142,11 +142,11 @@ visiting FILE." (interactive (list buffer-file-name nil)) (let ((vc-type (vc-backend-deduce file))) - (if vc-type - (setq vc-mode - (concat " " (or label (symbol-name vc-type)) - (if (and vc-rcs-status (eq vc-type 'RCS)) - (vc-rcs-status file))))) + (setq vc-mode + (and vc-type + (concat " " (or label (symbol-name vc-type)) + (if (and vc-rcs-status (eq vc-type 'RCS)) + (vc-rcs-status file))))) ;; force update of mode line (set-buffer-modified-p (buffer-modified-p)) vc-type))