GNU bug report logs - #14156
24.3.50; Timer firing after being canceled

Previous Next

Package: emacs;

Reported by: Stefan Monnier <monnier <at> IRO.UMontreal.CA>

Date: Mon, 8 Apr 2013 00:55:01 UTC

Severity: normal

Found in version 24.3.50

Done: Glenn Morris <rgm <at> gnu.org>

Bug is archived. No further changes may be made.

Full log


Message #8 received at 14156 <at> debbugs.gnu.org (full text, mbox):

From: Stefan Monnier <monnier <at> IRO.UMontreal.CA>
To: Michael Heerdegen <michael_heerdegen <at> web.de>
Cc: 14156 <at> debbugs.gnu.org
Subject: Re: 24.3.50; Timer firing after being canceled
Date: Sun, 07 Apr 2013 22:09:01 -0400
> If you call `start-the-timer', you get the message "Why is this ever
> reached?" over and over.  This obviously should not happen.

As mentioned elsewhere, this seems to be due to patch

   revno: 110138
   fixes bugs: http://debbugs.gnu.org/12447 http://debbugs.gnu.org/12326

I installed the patch below which seems to fix it.


        Stefan


=== modified file 'lisp/emacs-lisp/timer.el'
--- lisp/emacs-lisp/timer.el	2013-01-13 01:23:48 +0000
+++ lisp/emacs-lisp/timer.el	2013-04-08 01:53:53 +0000
@@ -314,7 +314,11 @@
               (save-current-buffer
                 (apply (timer--function timer) (timer--args timer)))
 	    (error (message "Error in timer: %S" err)))
-	  (if retrigger
+	  (when (and retrigger
+                     ;; If the timer's been canceled, don't "retrigger" it
+                     ;; since it might still be in the copy of timer-list kept
+                     ;; by keyboard.c:timer_check (bug#14156).
+                     (memq timer timer-list))
 	      (setf (timer--triggered timer) nil)))
       (error "Bogus timer event"))))
 





This bug report was last modified 12 years and 32 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.