[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Emacs-diffs] Changes to emacs/lisp/add-log.el,v

From: Glenn Morris
Subject: [Emacs-diffs] Changes to emacs/lisp/add-log.el,v
Date: Sat, 06 Sep 2008 19:47:15 +0000

CVSROOT:        /sources/emacs
Module name:    emacs
Changes by:     Glenn Morris <gm>       08/09/06 19:47:14

Index: add-log.el
RCS file: /sources/emacs/emacs/lisp/add-log.el,v
retrieving revision 1.222
retrieving revision 1.223
diff -u -b -r1.222 -r1.223
--- add-log.el  6 Sep 2008 19:38:35 -0000       1.222
+++ add-log.el  6 Sep 2008 19:47:14 -0000       1.223
@@ -686,16 +686,17 @@
 Optional arg BUFFER-FILE overrides `buffer-file-name'."
   ;; If we are called from a diff, first switch to the source buffer;
   ;; in order to respect buffer-local settings of change-log-default-name, etc.
-  (let ((buff (if (eq major-mode 'diff-mode)
-                 (car (ignore-errors (diff-find-source-location))))))
-    (with-current-buffer (if (buffer-live-p buff) buff
-                          (current-buffer))
+  (with-current-buffer (let ((buff (if (eq major-mode 'diff-mode)
+                                      (car (ignore-errors
+                                            (diff-find-source-location))))))
+                        (if (buffer-live-p buff) buff
+                          (current-buffer)))
       ;; If user specified a file name or if this buffer knows which one to 
       ;; just use that.
       (or file-name
          (setq file-name (and change-log-default-name
                               (file-name-directory change-log-default-name)
-                              change-log-default-name)))
+                            change-log-default-name))
        ;; Chase links in the source file
        ;; and use the change log in the dir where it points.
@@ -728,9 +729,9 @@
          ;; If we found a change log in a parent, use that.
          (if (or (get-file-buffer file1) (file-exists-p file1))
-             (setq file-name file1))))
+               (setq file-name file1)))))
       ;; Make a local variable in this buffer so we needn't search again.
-      (set (make-local-variable 'change-log-default-name) file-name)))
+    (set (make-local-variable 'change-log-default-name) file-name))
 (defun add-log-file-name (buffer-file log-file)

reply via email to

[Prev in Thread] Current Thread [Next in Thread]