calc-forms.patch revision 3626
3626N/A# Prevent uninterruptible infinite loop. This is the fix for
3626N/A# 20270656 calc: sign change of hh.mm value puts Emacs into tight loop
3626N/A# See components/emacs/README.
3626N/A#
3626N/A--- emacs-24.3.orig/lisp/calc/calc-forms.el 2013-01-01 13:37:17.000000000 -0700
3626N/A+++ emacs-24.3/lisp/calc/calc-forms.el 2015-01-02 14:57:36.824358166 -0700
3626N/A@@ -271,7 +271,10 @@
3626N/A (m (math-normalize (nth 2 a)))
3626N/A (s (let ((calc-internal-prec (max (- calc-internal-prec 4) 3)))
3626N/A (math-normalize (nth 3 a)))))
3626N/A- (if (math-negp h)
3626N/A+ (if (or
3626N/A+ (math-negp h)
3626N/A+ (and (= h 0) (math-negp m))
3626N/A+ (and (= h 0) (= m 0) (math-negp s)))
3626N/A (progn
3626N/A (if (math-posp s)
3626N/A (setq s (math-add s -60)