]> git.eshelyaron.com Git - emacs.git/commitdiff
* emacs-lisp/byte-opt.el (byte-optimize-form-code-walker): Avoid
authorAndreas Schwab <schwab@linux-m68k.org>
Mon, 27 Sep 2010 17:14:58 +0000 (19:14 +0200)
committerAndreas Schwab <schwab@linux-m68k.org>
Mon, 27 Sep 2010 17:14:58 +0000 (19:14 +0200)
infinite recursion on erroneous lambda form.  (Bug#7114)

lisp/ChangeLog
lisp/emacs-lisp/byte-opt.el

index 0bbc1648dec40849d398d1dc5a6a8d4e2b93321d..45f32afa0a8d82835f0458fb00930e6507bdac7a 100644 (file)
@@ -1,3 +1,8 @@
+2010-09-27  Andreas Schwab  <schwab@linux-m68k.org>
+
+       * emacs-lisp/byte-opt.el (byte-optimize-form-code-walker): Avoid
+       infinite recursion on erroneous lambda form.  (Bug#7114)
+
 2010-09-27  Kenichi Handa  <handa@m17n.org>
 
        * tar-mode.el (tar-header-block-tokenize): Decode filenames in
index e461010a6ce767a76d122b514e81f591f2faa1e0..4950511ebe2619c32b010c29cd475690f5797f66 100644 (file)
                form))
          ((or (byte-code-function-p fn)
               (eq 'lambda (car-safe fn)))
-           (byte-optimize-form-code-walker
-            (byte-compile-unfold-lambda form)
-            for-effect))
+          (let ((newform (byte-compile-unfold-lambda form)))
+            (if (eq newform form)
+                ;; Some error occured, avoid infinite recursion
+                form
+              (byte-optimize-form-code-walker newform for-effect))))
          ((memq fn '(let let*))
           ;; recursively enter the optimizer for the bindings and body
           ;; of a let or let*.  This for depth-firstness: forms that