From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Reiner Steib Newsgroups: gmane.emacs.devel,gmane.emacs.gnus.general Subject: Risky variables in Gnus (was: Warning: `mapcar' called for effect; use `mapc' or `dolist') Date: Sat, 27 Oct 2007 12:46:22 +0200 Message-ID: References: <200710200643.l9K6h9gk021348@oogie-boogie.ics.uci.edu> <200710222007.l9MK7fRZ022140@oogie-boogie.ics.uci.edu> 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 1193489697 14836 80.91.229.12 (27 Oct 2007 12:54:57 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Sat, 27 Oct 2007 12:54:57 +0000 (UTC) Cc: ding@gnus.org, emacs-devel@gnu.org To: Richard Stallman Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Sat Oct 27 14:54:57 2007 Return-path: Envelope-to: ged-emacs-devel@m.gmane.org Original-Received: from lists.gnu.org ([199.232.76.165]) by lo.gmane.org with esmtp (Exim 4.50) id 1IllBn-0005be-Ov for ged-emacs-devel@m.gmane.org; Sat, 27 Oct 2007 14:54:56 +0200 Original-Received: from localhost ([127.0.0.1] helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1IllBe-0001Mc-Tl for ged-emacs-devel@m.gmane.org; Sat, 27 Oct 2007 08:54:46 -0400 Original-Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1IllBb-0001KU-3z for emacs-devel@gnu.org; Sat, 27 Oct 2007 08:54:43 -0400 Original-Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1IllBZ-0001Is-Cz for emacs-devel@gnu.org; Sat, 27 Oct 2007 08:54:42 -0400 Original-Received: from [199.232.76.173] (helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1IllBZ-0001Il-8R for emacs-devel@gnu.org; Sat, 27 Oct 2007 08:54:41 -0400 Original-Received: from mail.uni-ulm.de ([134.60.1.11]) by monty-python.gnu.org with esmtps (TLS-1.0:DHE_RSA_AES_256_CBC_SHA1:32) (Exim 4.60) (envelope-from ) id 1IllBU-0002p7-Lw; Sat, 27 Oct 2007 08:54:37 -0400 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 l9RCsXeV012468; Sat, 27 Oct 2007 14:54:33 +0200 (MEST) Original-Received: from localhost (bridgekeeper.physik.uni-ulm.de [134.60.41.37]) by bridgekeeper.physik.uni-ulm.de (Postfix) with ESMTP id 3C20012C8E; Sat, 27 Oct 2007 14:54:32 +0200 (CEST) X-Face: mtjf/D:es1T0wHO:&CJ'ZXe"l; 3C--rw\z!{`eFwL){|]RpI+4{u25L=5C /0>KuGeTsk<~<&NE-AKV1560e!+RJeyWmSskkrJm?[vUV#66{T_m|Ae<||Ku#Mk5`y&O`n~z2; n8eP J5#2h@2eQgV@E70IY_0WlEx!"&giy{+\%h1LJox$zv@/l%ZmU4^tZA>xQpnkUBVC5.jpg#0'(+2?Rs )NAr:>3<=WxHE$ktbLysDIM5TbmHu*3 (Richard Stallman's message of "Tue, 23 Oct 2007 06:39:11 -0400") User-Agent: Gnus/5.110007 (No Gnus v0.7) Emacs/23.0.50 (gnu/linux) X-DCC-HP_X86_64_8CPU-Metrics: poseidon 1245; 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 l9RCsXeV012468 X-detected-kernel: by monty-python.gnu.org: Genre and OS details not recognized. X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "Emacs development discussions." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Original-Sender: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Errors-To: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.devel:81838 gmane.emacs.gnus.general:65463 Archived-At: On Tue, Oct 23 2007, Richard Stallman wrote: > > > (defun gnus-group-highlight-line () > > > "Highlight the current line according to `gnus-group-highli= ght'." > [...] > > It seems that `mailp' is not used in that function.=20 > > `mailp' is used implicitly through the variable `gnus-group-highlig= ht' > which is let-bound to `list'. `list' is used in the body of the > let-form. [...] > I added a `risky-local-variable' property to `gnus-group-highlight'. Fine with me. But I can't imagine a way to exploit this. Setting `gnus-group-highlight' buffer-locally (using local variables in a file) won't effect Gnus *Group* buffer where the variable is evaluated. > Are there any other such variables in Gnus which contain forms to > evaluate? Yes, a quick =ABgrep -inH -e ':tag "Form"' *.el=BB [1] showed some hits (there are more probably). However, I neither can see a way to maliciously manipulate these variables through file local variables. I someone can think of a way, please let me know. I think the vast majority of Gnus functions are _not_ evaluated in file-visiting buffers. But it's fine with me to mark all these variables as risky. Here's a list of such variable I found so far: `gnus-button-alist', `gnus-header-button-alist', `gnus-group-charter-alist', `gnus-group-highlight', `gnus-group-icon-list', `gnus-summary-highlight', `mm-charset-eval-alist'. Bye, Reiner. --8<---------------cut here---------------start------------->8--- -*- mode: grep; default-directory: "~/src/links/plain_No/lisp/" -*- Grep started at Sat Oct 27 12:29:54 grep -inH -e ':tag "Form"' *.el gnus-art.el:7181: (sexp :tag "Form") gnus-art.el:7220: (sexp :tag "Form") gnus.el:1482: :type '(repeat (cons (string :tag "Hierarchy") (sexp :tag = "Form")))) gnus-group.el:384: :type '(repeat (cons (sexp :tag "Form") face))) gnus-group.el:422: :type '(repeat (cons (sexp :tag "Form") file))) gnus-sum.el:1081: :type '(repeat (cons (sexp :tag "Form" nil) mm-util.el:431: (symbol :tag "form")))) Grep finished (matches found) at Sat Oct 27 12:29:55 --8<---------------cut here---------------end--------------->8--- --=20 ,,, (o o) ---ooO-(_)-Ooo--- | PGP key available | http://rsteib.home.pages.de/