emacs-diffs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Emacs-diffs] /srv/bzr/emacs/trunk r102630: Merge changes made in Gnus t


From: Katsumi Yamaoka
Subject: [Emacs-diffs] /srv/bzr/emacs/trunk r102630: Merge changes made in Gnus trunk.
Date: Sat, 11 Dec 2010 01:27:14 +0000
User-agent: Bazaar (2.0.3)

------------------------------------------------------------
revno: 102630
author: Gnus developers
committer: Katsumi Yamaoka <address@hidden>
branch nick: trunk
timestamp: Sat 2010-12-11 01:27:14 +0000
message:
  Merge changes made in Gnus trunk.
  
  nnir.el (nnir-request-expire-articles): Only allow article deletion.
  message.el (message-bogus-recipient-p): Set address to "" if nil.
  gnus-gravatar.el (gnus-gravatar-transform-address): Fix error when email 
address is nil.
  proto-stream.el (proto-stream-open-network-only): New function to have a way 
to specify non-STARTTLS upgrade connections.
modified:
  doc/misc/gnus.texi
  lisp/gnus/ChangeLog
  lisp/gnus/gnus-gravatar.el
  lisp/gnus/message.el
  lisp/gnus/nnir.el
  lisp/gnus/nntp.el
  lisp/gnus/proto-stream.el
=== modified file 'doc/misc/gnus.texi'
--- a/doc/misc/gnus.texi        2010-12-06 23:27:17 +0000
+++ b/doc/misc/gnus.texi        2010-12-11 01:27:14 +0000
@@ -14445,6 +14445,9 @@
 connection will be upgraded to an encrypted @acronym{STARTTLS}
 connection automatically.
 
address@hidden network-only
+The same as the above, but don't do automatic @acronym{STARTTLS} upgrades.
+
 @findex nntp-open-tls-stream
 @item nntp-open-tls-stream
 Opens a connection to a server over a @dfn{secure} channel.  To use

=== modified file 'lisp/gnus/ChangeLog'
--- a/lisp/gnus/ChangeLog       2010-12-09 23:20:33 +0000
+++ b/lisp/gnus/ChangeLog       2010-12-11 01:27:14 +0000
@@ -1,3 +1,21 @@
+2010-12-10  Lars Magne Ingebrigtsen  <address@hidden>
+
+       * proto-stream.el (proto-stream-open-network-only): New function to
+       have a way to specify non-STARTTLS upgrade connections.
+
+2010-12-10  Julien Danjou  <address@hidden>
+
+       * gnus-gravatar.el (gnus-gravatar-transform-address): Fix error when
+       email address is nil.
+
+       * message.el (message-bogus-recipient-p): Set address to "" if nil.
+
+2010-12-10  Andrew Cohen  <address@hidden>
+
+       * nnir.el (nnir-request-expire-articles): Ignore expiry except for
+       deletion.
+       (nnir-run-imap): Only need to parse list once.
+
 2010-12-09  Lars Magne Ingebrigtsen  <address@hidden>
 
        * shr.el (shr-tag-script): Ignore <script>.

=== modified file 'lisp/gnus/gnus-gravatar.el'
--- a/lisp/gnus/gnus-gravatar.el        2010-12-02 22:21:31 +0000
+++ b/lisp/gnus/gnus-gravatar.el        2010-12-11 01:27:14 +0000
@@ -65,7 +65,7 @@
        (when (or force
                  (not (and gnus-gravatar-too-ugly
                            (or (string-match gnus-gravatar-too-ugly
-                                             (cadr address))
+                                             (or (cadr address) ""))
                                (and name
                                     (string-match gnus-gravatar-too-ugly
                                                   name))))))

=== modified file 'lisp/gnus/message.el'
--- a/lisp/gnus/message.el      2010-12-07 02:01:00 +0000
+++ b/lisp/gnus/message.el      2010-12-11 01:27:14 +0000
@@ -4261,9 +4261,10 @@
   ;; FIXME: How about "address@hidden", when the MTA adds ".domain.tld"?
   (let (found)
     (mapc (lambda (address)
-           (setq address (cadr address))
+           (setq address (or (cadr address) ""))
            (when
-               (or (not
+               (or (string= "" address)
+                    (not
                     (or
                      (not (string-match "@" address))
                      (string-match
@@ -4277,7 +4278,7 @@
                                               "\\|")
                                  message-bogus-addresses)))
                           (string-match re address))))
-                        (push address found)))
+              (push address found)))
          ;;
          (mail-extract-address-components recipients t))
     found))

=== modified file 'lisp/gnus/nnir.el'
--- a/lisp/gnus/nnir.el 2010-12-08 14:41:37 +0000
+++ b/lisp/gnus/nnir.el 2010-12-11 01:27:14 +0000
@@ -688,23 +688,25 @@
          (gnus-group-real-name to-newsgroup)))))
 
 (deffoo nnir-request-expire-articles (articles group &optional server force)
-  (let ((articles-by-group (nnir-categorize
-                           articles nnir-article-group nnir-article-ids))
-       not-deleted)
-    (while (not (null articles-by-group))
-      (let* ((group-articles (pop articles-by-group))
-            (artgroup (car group-articles))
-            (articleids (cadr group-articles))
-            (artlist (sort (mapcar 'cdr articleids) '<)))
-       (unless (gnus-check-backend-function 'request-expire-articles
-                                            artgroup)
-         (error "The group %s does not support article deletion" artgroup))
-       (unless (gnus-check-server (gnus-find-method-for-group artgroup))
-         (error "Couldn't open server for group %s" artgroup))
-       (push (gnus-request-expire-articles
-              artlist artgroup force)
-             not-deleted)))
-    (sort (delq nil not-deleted) '<)))
+  (if force
+    (let ((articles-by-group (nnir-categorize
+                             articles nnir-article-group nnir-article-ids))
+         not-deleted)
+      (while (not (null articles-by-group))
+       (let* ((group-articles (pop articles-by-group))
+              (artgroup (car group-articles))
+              (articleids (cadr group-articles))
+              (artlist (sort (mapcar 'cdr articleids) '<)))
+         (unless (gnus-check-backend-function 'request-expire-articles
+                                              artgroup)
+           (error "The group %s does not support article deletion" artgroup))
+         (unless (gnus-check-server (gnus-find-method-for-group artgroup))
+           (error "Couldn't open server for group %s" artgroup))
+         (push (gnus-request-expire-articles
+                artlist artgroup force)
+               not-deleted)))
+      (sort (delq nil not-deleted) '<))
+    articles))
 
 (deffoo nnir-warp-to-article ()
   (let* ((cur (if (> (gnus-summary-article-number) 0)
@@ -792,12 +794,13 @@
                                                    (nnir-imap-make-query
                                                     criteria qstring)))))
                      (mapc
-                      (lambda (artnum) (push (vector group artnum 100) artlist)
-                        (setq arts (1+ arts)))
-                      (and (car result)
-                           (delete 0 (mapcar #'string-to-number
-                                             (cdr (assoc "SEARCH"
-                                                         (cdr result)))))))
+                      (lambda (artnum)
+                        (let ((artn (string-to-number artnum)))
+                          (when (> artn 0)
+                            (push (vector group artn 100)
+                                  artlist)
+                            (setq arts (1+ arts)))))
+                      (and (car result) (cdr (assoc "SEARCH" (cdr result)))))
                      (message "Searching %s... %d matches" group arts)))
                  (message "Searching %s...done" group))
              (quit nil))
@@ -1581,8 +1584,10 @@
          (or nnir-summary-line-format gnus-summary-line-format))
     (remove-hook 'gnus-summary-article-delete-hook 'gnus-registry-action t)
     (remove-hook 'gnus-summary-article-move-hook 'gnus-registry-action t)
+    (remove-hook 'gnus-summary-article-expire-hook 'gnus-registry-action t)
     (add-hook 'gnus-summary-article-delete-hook 'nnir-registry-action t t)
-    (add-hook 'gnus-summary-article-move-hook 'nnir-registry-action t t)))
+    (add-hook 'gnus-summary-article-move-hook 'nnir-registry-action t t)
+    (add-hook 'gnus-summary-article-expire-hook 'nnir-registry-action t t)))
 
 
 

=== modified file 'lisp/gnus/nntp.el'
--- a/lisp/gnus/nntp.el 2010-12-05 22:17:34 +0000
+++ b/lisp/gnus/nntp.el 2010-12-11 01:27:14 +0000
@@ -87,6 +87,8 @@
 
 Direct connections:
 - `nntp-open-network-stream' (the default),
+- `network-only' (the same as the above, but don't do automatic
+  STARTTLS upgrades).
 - `nntp-open-ssl-stream',
 - `nntp-open-tls-stream',
 - `nntp-open-netcat-stream'.
@@ -1267,6 +1269,7 @@
              (let ((coding-system-for-read nntp-coding-system-for-read)
                    (coding-system-for-write nntp-coding-system-for-write)
                    (map '((nntp-open-network-stream network)
+                          (network-only network-only)
                           (nntp-open-ssl-stream tls)
                           (nntp-open-tls-stream tls))))
                (if (assoc nntp-open-connection-function map)

=== modified file 'lisp/gnus/proto-stream.el'
--- a/lisp/gnus/proto-stream.el 2010-12-06 23:27:17 +0000
+++ b/lisp/gnus/proto-stream.el 2010-12-11 01:27:14 +0000
@@ -75,10 +75,11 @@
 The PARAMETERS is a keyword list that can have the following
 values:
 
-:type -- either `network', `tls', `shell' or `starttls'.  If
-omitted, the default is `network'.  `network' will be
-opportunistically upgraded to STARTTLS if both the server and
-Emacs supports it.
+:type -- either `network', `network-only, `tls', `shell' or
+`starttls'.  If omitted, the default is `network'.  `network'
+will be opportunistically upgraded to STARTTLS if both the server
+and Emacs supports it.  If you don't want STARTTLS upgrades, use
+`network-only'.
 
 :end-of-command -- a regexp saying what the end of a command is.
 This defaults to \"\\n\".
@@ -109,6 +110,9 @@
                 stream)
            greeting capabilities))))
 
+(defun proto-stream-open-network-only (name buffer host service parameters)
+  (open-network-stream name buffer host service))
+
 (defun proto-stream-open-network (name buffer host service parameters)
   (let* ((start (with-current-buffer buffer (point)))
         (stream (open-network-stream name buffer host service))


reply via email to

[Prev in Thread] Current Thread [Next in Thread]