From mboxrd@z Thu Jan 1 00:00:00 1970 X-Msuck: nntp://news.gmane.io/gmane.emacs.gnus.general/9300 Path: main.gmane.org!not-for-mail From: Paul Stodghill Newsgroups: gmane.emacs.gnus.general Subject: Final (?) fix for gnus-demon.el Date: 08 Jan 1997 08:09:56 -0500 Sender: stodghil@CS.Cornell.EDU Message-ID: NNTP-Posting-Host: coloc-standby.netfonds.no Mime-Version: 1.0 (generated by tm-edit 7.100) Content-Type: text/plain; charset=US-ASCII X-Trace: main.gmane.org 1035149345 17605 80.91.224.250 (20 Oct 2002 21:29:05 GMT) X-Complaints-To: usenet@main.gmane.org NNTP-Posting-Date: Sun, 20 Oct 2002 21:29:05 +0000 (UTC) Return-Path: Original-Received: from ifi.uio.no (0@ifi.uio.no [129.240.64.2]) by deanna.miranova.com (8.8.4/8.8.4) with SMTP id FAA02609 for ; Wed, 8 Jan 1997 05:51:48 -0800 Original-Received: from simon.cs.cornell.edu (SIMON.CS.CORNELL.EDU [128.84.154.10]) by ifi.uio.no with ESMTP (8.6.11/ifi2.4) id for ; Wed, 8 Jan 1997 14:10:05 +0100 Original-Received: from cloyd.cs.cornell.edu (CLOYD.CS.CORNELL.EDU [128.84.227.15]) by simon.cs.cornell.edu (8.8.4/8.8.4/R-1.7) with ESMTP id IAA01628 for ; Wed, 8 Jan 1997 08:10:02 -0500 (EST) Original-Received: from hoho.cs.cornell.edu (HOHO.CS.CORNELL.EDU [128.84.211.72]) by cloyd.cs.cornell.edu (8.8.4/8.8.4/M-1.8) with ESMTP id IAA17765 for ; Wed, 8 Jan 1997 08:10:00 -0500 (EST) Original-Received: (from stodghil@localhost) by hoho.cs.cornell.edu (8.8.4/8.8.4/C-1.2) id IAA09846; Wed, 8 Jan 1997 08:09:57 -0500 (EST) Original-To: ding@ifi.uio.no Original-Lines: 29 X-Mailer: Red Gnus v0.79/XEmacs 19.14 Xref: main.gmane.org gmane.emacs.gnus.general:9300 X-Report-Spam: http://spam.gmane.org/gmane.emacs.gnus.general:9300 In 0.79, the demon still runs jobs, even when Emacs is not idle. Here's the fix. --- rgnus-0.79/lisp/gnus-demon.el.orig Tue Jan 7 12:40:05 1997 +++ rgnus-0.79/lisp/gnus-demon.el Tue Jan 7 13:34:55 1997 @@ -184,10 +184,14 @@ (unless (zerop time) (setcar (nthcdr 1 handler) (decf time))) (and (zerop time) ; If the timer now is zero... - (or (not (setq idle (nth 2 handler))) ; Don't care about idle. - (and (numberp idle) ; Numerical idle... - (< idle gnus-demon-idle-time)) ; Idle timed out. - idle) ; Or just need to be idle. + ;; Test for appropriate idleness + (progn + (setq idle (nth 2 handler)) + (cond + ((null idle) t) ; Don't care about idle. + ((numberp idle) ; Numerical idle... + (< idle gnus-demon-idle-time)) ; Idle timed out. + (t (< 0 gnus-demon-idle-time)))) ; Or just need to be idle. ;; So we call the handler. (progn (funcall (car handler)) -- Paul Stodghill http://www.cs.cornell.edu/home/stodghil/home.html