From 3c2e52cde9960da063b34e7c7abdd08969623f2f Mon Sep 17 00:00:00 2001 From: Thien-Thi Nguyen Date: Sun, 20 Jan 2008 20:29:47 +0000 Subject: [PATCH] (vc-process-sentinel): Fix bug introduced in last change: Set mode-line-process with P's buffer made temporarily current. --- lisp/vc.el | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/lisp/vc.el b/lisp/vc.el index 26cf32999b6..497ba1e0df4 100644 --- a/lisp/vc.el +++ b/lisp/vc.el @@ -958,13 +958,14 @@ BUF defaults to \"*vc*\", can be a string and will be created if necessary." (defvar vc-sentinel-movepoint) ;Dynamically scoped. (defun vc-process-sentinel (p s) - (let ((previous (process-get p 'vc-previous-sentinel))) + (with-current-buffer (process-buffer p) (setq mode-line-process (let ((status (process-status p))) ;; Leave mode-line uncluttered, normally. ;; (Let known any weirdness in-form-ally. ;-) --ttn (unless (eq 'exit status) - (format " (%s)" status)))) + (format " (%s)" status))))) + (let ((previous (process-get p 'vc-previous-sentinel))) (if previous (funcall previous p s)) (with-current-buffer (process-buffer p) (let (vc-sentinel-movepoint) -- 2.11.4.GIT