Gnus development mailing list
 help / color / mirror / Atom feed
* Corrupted score files with ... symbols
@ 2004-08-23  9:16 Florian Weimer
  2004-08-23  9:46 ` Katsumi Yamaoka
  0 siblings, 1 reply; 5+ messages in thread
From: Florian Weimer @ 2004-08-23  9:16 UTC (permalink / raw)


The patch below prevents Gnus from corrupting score files if
`print-level' is ever set to a non-nil value.  This kind of score file
corruption results in the following error message:

gnus-score-load-score-alist: Wrong type argument: listp, \.\.\.

(The fix is to remove the `...' symbol from the score file.  Some data
is lost.)

Okay to commit?

2004-08-23  Florian Weimer  <fw@deneb.enyo.de>

	* gnus-score.el (gnus-score-save): Bind `print-length' to nil, to
	prevent truncation of scoring rules.

	* score-mode.el (gnus-score-pretty-print): Likewise.

Index: gnus-score.el
===================================================================
RCS file: /usr/local/cvsroot/gnus/lisp/gnus-score.el,v
retrieving revision 7.12
diff -u -r7.12 gnus-score.el
--- gnus-score.el	20 May 2004 08:02:39 -0000	7.12
+++ gnus-score.el	23 Aug 2004 09:11:47 -0000
@@ -1387,6 +1387,7 @@
 (defun gnus-score-save ()
   ;; Save all score information.
   (let ((cache gnus-score-cache)
+	(print-length nil)
 	entry score file)
     (save-excursion
       (setq gnus-score-alist nil)
Index: score-mode.el
===================================================================
RCS file: /usr/local/cvsroot/gnus/lisp/score-mode.el,v
retrieving revision 7.2
diff -u -r7.2 score-mode.el
--- score-mode.el	20 May 2004 08:02:41 -0000	7.2
+++ score-mode.el	23 Aug 2004 09:11:55 -0000
@@ -93,7 +93,8 @@
   (goto-char (point-min))
   (let ((form (read (current-buffer))))
     (erase-buffer)
-    (let ((emacs-lisp-mode-syntax-table score-mode-syntax-table))
+    (let ((emacs-lisp-mode-syntax-table score-mode-syntax-table)
+	  (print-length nil))
       (pp form (current-buffer))))
   (goto-char (point-min)))
 




^ permalink raw reply	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2004-08-24  6:55 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2004-08-23  9:16 Corrupted score files with ... symbols Florian Weimer
2004-08-23  9:46 ` Katsumi Yamaoka
2004-08-23 11:08   ` Florian Weimer
2004-08-23 12:34     ` Katsumi Yamaoka
2004-08-24  6:55       ` Katsumi Yamaoka

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).