]> git.eshelyaron.com Git - emacs.git/commitdiff
(vc-process-sentinel): Fix bug introduced in last change:
authorThien-Thi Nguyen <ttn@gnuvola.org>
Sun, 20 Jan 2008 20:29:47 +0000 (20:29 +0000)
committerThien-Thi Nguyen <ttn@gnuvola.org>
Sun, 20 Jan 2008 20:29:47 +0000 (20:29 +0000)
Set mode-line-process with P's buffer made temporarily current.

lisp/vc.el

index 26cf32999b6844d4d57b622bab2b104c30f40df2..497ba1e0df4fff75ed24c16515a76a04d367b259 100644 (file)
@@ -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)