]> git.eshelyaron.com Git - emacs.git/commitdiff
(outline-up-heading): Fix check for top level to
authorMartin Rudalics <rudalics@gmx.at>
Mon, 21 Jan 2008 19:48:56 +0000 (19:48 +0000)
committerMartin Rudalics <rudalics@gmx.at>
Mon, 21 Jan 2008 19:48:56 +0000 (19:48 +0000)
avoid infinite looping in hide-other.

lisp/ChangeLog
lisp/outline.el

index b3e010f9b93bc682d46b5c41c53a8dd9594154d5..91ea02a2dbbd1eb8b9c879c2c778e4492cb210ec 100644 (file)
@@ -1,3 +1,8 @@
+2008-01-21  Martin Rudalics  <rudalics@gmx.at>
+
+       * outline.el (outline-up-heading): Fix check for top level to
+       avoid infinite looping in hide-other.
+
 2008-01-21  Thien-Thi Nguyen  <ttn@gnuvola.org>
 
        * vc.el (vc-process-sentinel): After calling the previous
index f075a4748103871ad21420fb96f4302d5d77311a..40340e10f42f67e73074164933b28c14021c25e7 100644 (file)
@@ -971,8 +971,8 @@ If INVISIBLE-OK is non-nil, also consider invisible lines."
        (or (eq last-command 'outline-up-heading) (push-mark)))
   (outline-back-to-heading invisible-ok)
   (let ((start-level (funcall outline-level)))
-    (if (eq start-level 1)
-       (error "Already at top level of the outline"))
+    (when (<= start-level 1)
+      (error "Already at top level of the outline"))
     (while (and (> start-level 1) (> arg 0) (not (bobp)))
       (let ((level start-level))
        (while (not (or (< level start-level) (bobp)))