From mboxrd@z Thu Jan 1 00:00:00 1970 X-Msuck: nntp://news.gmane.io/gmane.emacs.gnus.general/65886 Path: news.gmane.org!not-for-mail From: Reiner Steib Newsgroups: gmane.emacs.gnus.general Subject: Re: Problem with mail-source-report-new-mail Date: Wed, 05 Dec 2007 21:47:58 +0100 Message-ID: References: <87mysp5cfk.fsf@haakonst1.dyndns.org> Reply-To: Reiner Steib NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=iso-8859-1 Content-Transfer-Encoding: quoted-printable X-Trace: ger.gmane.org 1196887757 29670 80.91.229.12 (5 Dec 2007 20:49:17 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Wed, 5 Dec 2007 20:49:17 +0000 (UTC) Cc: bugs@gnus.org, ding@gnus.org To: =?iso-8859-1?Q?H=E5kon?= Stordahl Original-X-From: ding-owner+M14380@lists.math.uh.edu Wed Dec 05 21:49:26 2007 Return-path: Envelope-to: ding-account@gmane.org Original-Received: from util0.math.uh.edu ([129.7.128.18]) by lo.gmane.org with esmtp (Exim 4.50) id 1J01BN-0004JW-Lj for ding-account@gmane.org; Wed, 05 Dec 2007 21:49:25 +0100 Original-Received: from localhost ([127.0.0.1] helo=lists.math.uh.edu) by util0.math.uh.edu with smtp (Exim 4.63) (envelope-from ) id 1J01B4-0007BF-NW; Wed, 05 Dec 2007 14:49:06 -0600 Original-Received: from mx2.math.uh.edu ([129.7.128.33]) by util0.math.uh.edu with esmtps (TLSv1:AES256-SHA:256) (Exim 4.63) (envelope-from ) id 1J01B3-0007Ao-5e for ding@lists.math.uh.edu; Wed, 05 Dec 2007 14:49:05 -0600 Original-Received: from quimby.gnus.org ([80.91.231.51]) by mx2.math.uh.edu with esmtp (Exim 4.67) (envelope-from ) id 1J01Aw-0001x6-2M for ding@lists.math.uh.edu; Wed, 05 Dec 2007 14:49:04 -0600 Original-Received: from mail.uni-ulm.de ([134.60.1.11]) by quimby.gnus.org with esmtp (Exim 3.35 #1 (Debian)) id 1J01At-0002Tg-00; Wed, 05 Dec 2007 21:48:55 +0100 Original-Received: from bridgekeeper.physik.uni-ulm.de (bridgekeeper.physik.uni-ulm.de [134.60.41.37]) by mail.uni-ulm.de (8.14.1/8.14.1) with ESMTP id lB5Kmt9M016642; Wed, 5 Dec 2007 21:48:56 +0100 (MET) Original-Received: from localhost (bridgekeeper.physik.uni-ulm.de [134.60.41.37]) by bridgekeeper.physik.uni-ulm.de (Postfix) with ESMTP id D717712DD0; Wed, 5 Dec 2007 21:48:55 +0100 (CET) X-Face: 'bg&jY[8V'W&:=~6w"|>}#4/T;w~36ei4NNMyKRR.a$n=$|sWFPF1y]a\>6kc\*#GN]UDM| Ywv,vbL^XF1nIp\:F=$Ei2o&mEe:%N~,:3]vtQ~s9u$9izmX$IF@VgGl7/,^dbuM<3|AO2}.%|%?kZ 2Y=@\U!~cll^=8Z9ihKq%wmUe1Ky(#kl3T'>Qk0Ia3mCBsTk?E(,X Mail-Followup-To: =?iso-8859-1?Q?H=E5kon?= Stordahl , ding@gnus.org In-Reply-To: <87mysp5cfk.fsf@haakonst1.dyndns.org> (=?iso-8859-1?Q?=22H=E5?= =?iso-8859-1?Q?kon?= Stordahl"'s message of "Wed, 05 Dec 2007 17:33:19 +0100") User-Agent: Gnus/5.110007 (No Gnus v0.7) Emacs/22.1.50 (gnu/linux) X-DCC-dcc.uncw.edu-Metrics: poseidon 1201; Body=3 Fuz1=3 Fuz2=3 X-Virus-Scanned: by amavisd-new X-MIME-Autoconverted: from 8bit to quoted-printable by mail.uni-ulm.de id lB5Kmt9M016642 X-Spam-Score: -2.6 (--) List-ID: Precedence: bulk Xref: news.gmane.org gmane.emacs.gnus.general:65886 Archived-At: [ Adding ding@gnus ... ] On Wed, Dec 05 2007, H=E5kon Stordahl wrote: > No Gnus v0.7 > GNU Emacs 22.1.1 (i486-pc-linux-gnu, X toolkit, Xaw3d scroll bars) > of 2007-11-03 on pacem, modified by Debian > 200 news.gmane.org InterNetNews NNRP server INN 2.4.1 ready (posting ok= ). > > When calling the function mail-source-report-new-mail to enable > automatic mail checking, and unless display-time is enabled, the > following error message appears in the minibuffer each time when > checking or fetching new mail and the checking or fetching fails: > > Wrong type argument: arrayp, nil > > With debug-on-error set to t the error results in the following > backtrace: > > Debugger entered--Lisp error: (wrong-type-argument arrayp nil) > display-time-event-handler() > run-hooks(nnmail-post-get-new-mail-hook) > nnmail-get-new-mail(nnfolder #[nil "[...]" [nnfolder-buffer-alist buf= s gnus-buffer-live-p delq nnfolder-save-buffer kill-buffer nil] 4] "/home= /haakonst/Mail/" nil) > nnfolder-request-scan(nil "") > gnus-request-scan(nil (nnfolder "")) > gnus-read-active-file-1((nnfolder "") nil) > gnus-read-active-file() > gnus-group-get-new-news(nil) > call-interactively(gnus-group-get-new-news) > > The problem also appears to be present in Gnus 5.11. > > Although the documentation string of mail-source-report-new-mail > states that it only works when display-time is enabled, it could > handle the opposite more gracefully. The cause of the error seems to > be that the function display-time-event-handler gets called from the > hook nnmail-post-get-new-mail-hook and that doesn't seem to work if > not display-time is enabled. However, there already is a function, > gnus-display-time-event-handler defined in the file gnus-start.el, > which seems to be intended for handling exactly this, by calling > display-time-event-handler only if display-time is enabled. > > Thus, the following simple patch against the nightly snapshot of > 2008-11-28=20 Oh, could you please send us the sources? I'd be interested to see the new features in Gnus in the future. ;-) > suggests to substitute the references to display-time-event-handler > in function mail-source-report-new-mail with > gnus-display-time-event-handler instead: > > diff -Naur a/lisp/mail-source.el b/lisp/mail-source.el > --- a/lisp/mail-source.el 2007-11-27 23:42:52.000000000 +0000 > +++ b/lisp/mail-source.el 2007-11-30 04:39:08.000000000 +0000 > @@ -937,11 +937,11 @@ > #'mail-source-start-idle-timer)) > ;; When you get new mail, clear "Mail" from the mode line. > (add-hook 'nnmail-post-get-new-mail-hook > - 'display-time-event-handler) > + 'gnus-display-time-event-handler) > (message "Mail check enabled")) > (setq display-time-mail-function nil) > (remove-hook 'nnmail-post-get-new-mail-hook > - 'display-time-event-handler) > + 'gnus-display-time-event-handler) > (message "Mail check disabled")))) > > (defun mail-source-fetch-maildir (source callback) I don't use timers for Gnus. Does anyone see a problem with this patch? Bye, Reiner. --=20 ,,, (o o) ---ooO-(_)-Ooo--- | PGP key available | http://rsteib.home.pages.de/