(nntp-xref-number-is-evil): New server variable.
authorKatsumi Yamaoka <yamaoka@jpl.org>
Fri, 10 Aug 2007 02:34:29 +0000 (02:34 +0000)
committerKatsumi Yamaoka <yamaoka@jpl.org>
Fri, 10 Aug 2007 02:34:29 +0000 (02:34 +0000)
(nntp-find-group-and-number): If it is non-nil, don't trust article numbers in
 the Xref header.

lisp/ChangeLog
lisp/nntp.el

index 777d324..05c4134 100644 (file)
@@ -1,3 +1,9 @@
+2007-08-10  Katsumi Yamaoka  <yamaoka@jpl.org>
+
+       * nntp.el (nntp-xref-number-is-evil): New server variable.
+       (nntp-find-group-and-number): If it is non-nil, don't trust article
+       numbers in the Xref header.
+
 2007-08-09  Katsumi Yamaoka  <yamaoka@jpl.org>
 
        * gnus-agent.el (gnus-agent-read-group): New function.
index 5dff3a9..ce3a157 100644 (file)
@@ -194,6 +194,14 @@ by one.")
 If the gap between two consecutive articles is bigger than this
 variable, split the XOVER request into two requests.")
 
+(defvoo nntp-xref-number-is-evil nil
+  "*If non-nil, Gnus never trusts article numbers in the Xref header.
+Some news servers, e.g., ones running Diablo, run multiple engines
+having the same articles but article numbers are not kept synchronized
+between them.  If you connect to such a server, set this to a non-nil
+value, and Gnus never uses article numbers (that appear in the Xref
+header and vary by which engine is chosen) to refer to articles.")
+
 (defvoo nntp-prepare-server-hook nil
   "*Hook run before a server is opened.
 If can be used to set up a server remotely, for instance.  Say you
@@ -1702,7 +1710,8 @@ password contained in '~/.nntp-authinfo'."
                    (match-string 1 xref))
                   (t "")))
          (cond
-          ((and (setq xref (mail-fetch-field "xref"))
+          ((and (not nntp-xref-number-is-evil)
+                (setq xref (mail-fetch-field "xref"))
                 (string-match
                  (if group
                      (concat "\\(" (regexp-quote group) "\\):\\([0-9]+\\)")