emacs-elpa-diffs
[Top][All Lists]
Advanced

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

[elpa] 233/299: Prevent an infinite loop in TeX-command-expand.


From: Stefan Monnier
Subject: [elpa] 233/299: Prevent an infinite loop in TeX-command-expand.
Date: Sun, 02 Nov 2014 03:11:40 +0000

monnier pushed a commit to branch externals/auctex
in repository elpa.

commit e6bcd3a0c5864fca0b029f316e0add69ce04c8e0
Author: Mosè Giordano <address@hidden>
Date:   Sat Mar 15 12:59:26 2014 +0100

    Prevent an infinite loop in TeX-command-expand.
    
    * tex.el (TeX-view-command-raw): Throw an error when `spec' is
    nil, otherwise when the function returns nil `TeX-command-expand'
    enters an infinite loop.
---
 ChangeLog |    4 ++++
 tex.el    |    4 ++++
 2 files changed, 8 insertions(+), 0 deletions(-)

diff --git a/ChangeLog b/ChangeLog
index ab2c75c..f0ca214 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,5 +1,9 @@
 2014-03-15  Mos� Giordano  <address@hidden>
 
+       * tex.el (TeX-view-command-raw): Throw an error when `spec' is
+       nil, otherwise when the function returns nil `TeX-command-expand'
+       enters an infinite loop.
+
        * style/paralist.el: Update copyright years.
        ("paralist"): Use `LaTeX-provided-package-options-member' to
        conditionally define environments.
diff --git a/tex.el b/tex.el
index 23e99a0..796b1d8 100644
--- a/tex.el
+++ b/tex.el
@@ -1304,6 +1304,10 @@ predicates are true, nil otherwise."
           (prin1-to-string spec))
          ((stringp spec)
           spec)
+         ((null spec)
+          (error
+           (format "Unknown %S viewer. \
+Check the `TeX-view-program-selection' variable." viewer)))
          (t
           ;; Build the unexpanded command line.  Pieces with predicates are
           ;; only added if the predicate is evaluated positively.



reply via email to

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