[Date Prev][Date Next]
[Chronological]
[Thread]
[Top]
nnimap 0.114 -> 0.115 patches
- To: nnimap@extundo.com
- Subject: nnimap 0.114 -> 0.115 patches
- From: Simon Josefsson <jas@pdc.kth.se>
- Date: 13 Jun 1999 14:41:15 +0200
- User-Agent: Gnus/5.070086 (Pterodactyl Gnus v0.86) Emacs/20.3.10
Index: nnimap/ChangeLog
diff -u nnimap/ChangeLog:1.228 nnimap/ChangeLog:1.232
--- nnimap/ChangeLog:1.228 Fri Jun 4 06:45:01 1999
+++ nnimap/ChangeLog Sun Jun 13 05:14:58 1999
@@ -1,4 +1,25 @@
+1999-06-13 Simon Josefsson <jas@pdc.kth.se>
+
+ * nnimap 0.115 released.
+
+ * nnimap.el (nnimap-request-article-part): Message article fetch.
+
+ * imap.el (imap-mailbox-examine): New function.
+ (imap-mailbox-expunge): Only expunge when mailbox open.
+ (imap-mailbox-close): Only close when mailbox open.
+ (imap-kerberos4-open):
+ (imap-ssl-open-1):
+ (imap-network-open): Use insert-buffer-substring instead of
+ insert-buffer.
+
+1999-06-09 Simon Josefsson <jas@pdc.kth.se>
+
+ * imap.el (imap-parse-acl): Don't infloop.
+
1999-06-04 Simon Josefsson <jas@pdc.kth.se>
+
+ * nnimap.el (nnimap-request-article-part): Handle non-existant
+ articles.
* nnimap 0.114 released.
Index: nnimap/imap.el
diff -u nnimap/imap.el:1.143 nnimap/imap.el:1.147
--- nnimap/imap.el:1.143 Thu Jun 3 06:38:54 1999
+++ nnimap/imap.el Sun Jun 13 05:13:41 1999
@@ -356,7 +356,7 @@
(imap-disable-multibyte)
(buffer-disable-undo)
(goto-char (point-max))
- (insert-buffer buffer)))
+ (insert-buffer-substring buffer)))
(let ((response (match-string 1)))
(erase-buffer)
(message "Kerberized IMAP connection: %s" response)
@@ -392,7 +392,7 @@
(imap-disable-multibyte)
(buffer-disable-undo)
(goto-char (point-max))
- (insert-buffer buffer)))
+ (insert-buffer-substring buffer)))
(erase-buffer))
(when (memq (process-status process) '(open run))
process))))
@@ -424,7 +424,7 @@
(imap-disable-multibyte)
(buffer-disable-undo)
(goto-char (point-max))
- (insert-buffer buffer)))
+ (insert-buffer-substring buffer)))
(when (memq (process-status process) '(open run))
process))))
@@ -715,6 +715,10 @@
imap-mailbox-data old-data)
nil)))))
+(defun imap-mailbox-examine (mailbox &optional buffer)
+ "Examine MAILBOX on server in BUFFER"
+ (imap-mailbox-select mailbox buffer 'exmine))
+
(defun imap-mailbox-unselect (&optional buffer)
"Close current folder in BUFFER, without expunging articles."
(with-current-buffer (or buffer (current-buffer))
@@ -734,18 +738,19 @@
"Expunge articles in current folder in BUFFER. If BUFFER is
nil the current buffer is assumed."
(with-current-buffer (or buffer (current-buffer))
- (unless (eq imap-state 'examine)
+ (when (and imap-current-mailbox (not (eq imap-state 'examine)))
(imap-ok-p (imap-send-command-wait "EXPUNGE")))))
(defun imap-mailbox-close (&optional buffer)
"Expunge articles and close current folder in BUFFER. If BUFFER is
nil the current buffer is assumed."
(with-current-buffer (or buffer (current-buffer))
- (when (imap-ok-p (imap-send-command-wait "CLOSE"))
- (setq imap-current-mailbox nil
- imap-message-data nil
- imap-state 'auth)
- t)))
+ (when (and imap-current-mailbox
+ (imap-ok-p (imap-send-command-wait "CLOSE")))
+ (setq imap-current-mailbox nil
+ imap-message-data nil
+ imap-state 'auth)
+ t)))
(defun imap-mailbox-create (mailbox &optional buffer)
"Create MAILBOX on server in BUFFER. If BUFFER is nil the current
@@ -1740,16 +1745,15 @@
;; rights ::= astring
(defun imap-parse-acl ()
- (let ((mailbox (imap-parse-mailbox)))
- (when (eq (char-after) ?\ )
- (let (acl)
- (while (eq (char-after) ?\ )
- (let (identifier rights)
- (setq identifier (imap-parse-astring))
- (when (equal (char-after) ?\ )
- (setq rights (imap-parse-astring))
- (setq acl (append acl (list (cons identifier rights)))))))
- (imap-mailbox-put 'acl acl mailbox)))))
+ (let ((mailbox (imap-parse-mailbox))
+ identifier rights acl)
+ (while (eq (char-after) ?\ )
+ (imap-forward)
+ (setq identifier (imap-parse-astring))
+ (imap-forward)
+ (setq rights (imap-parse-astring))
+ (setq acl (append acl (list (cons identifier rights)))))
+ (imap-mailbox-put 'acl acl mailbox)))
;; flag-list = "(" [flag *(SP flag)] ")"
;;
Index: nnimap/nnimap.el
diff -u nnimap/nnimap.el:1.181 nnimap/nnimap.el:1.183
--- nnimap/nnimap.el:1.181 Fri Jun 4 06:44:50 1999
+++ nnimap/nnimap.el Sun Jun 13 05:14:48 1999
@@ -99,7 +99,7 @@
(gnus-declare-backend "nnimap" 'mail 'address 'prompt-address
'physical-address)
-(defconst nnimap-version "nnimap 0.114")
+(defconst nnimap-version "nnimap 0.115")
(defvoo nnimap-address nil
"Address of physical IMAP server. If nil, use the virtual server's name.")
@@ -516,22 +516,19 @@
(when (nnimap-possibly-change-group group server)
(with-current-buffer (or to-buffer nntp-server-buffer)
(erase-buffer)
- (let (artnum)
- (insert (nnimap-demule
- (or (imap-fetch
- (setq artnum
- (if (stringp article)
- (car-safe (imap-search
- (format "HEADER Message-Id %s"
- article)
- nnimap-server-buffer))
- article))
- part prop nil nnimap-server-buffer)
+ (and (stringp article)
+ (setq article (car-safe (imap-search
+ (format "HEADER Message-Id %s" article)
+ nnimap-server-buffer))))
+ (when article
+ (gnus-message 9 "nnimap: Fetching (part of) article %d..." article)
+ (insert (nnimap-demule
+ (or (imap-fetch article part prop nil nnimap-server-buffer)
"")))
- (nnheader-ms-strip-cr)
- (if (bobp)
- (nnheader-report 'nnimap "No such article")
- (cons group artnum))))))
+ (nnheader-ms-strip-cr))
+ (if (bobp)
+ (nnheader-report 'nnimap "No such article")
+ (cons group article)))))
(deffoo nnimap-request-article (article &optional group server to-buffer)
(nnimap-request-article-part
@@ -592,7 +589,7 @@
(deffoo nnimap-request-list (&optional server)
(when (nnimap-possibly-change-server server)
(with-current-buffer nntp-server-buffer
- (gnus-message 5 "Generating active list for %s..." server)
+ (gnus-message 5 "nnimap: Generating active list for %s..." server)
(erase-buffer)
(dolist (pattern (nnimap-pattern-to-list-arguments
nnimap-list-pattern))
@@ -604,7 +601,7 @@
(string-match " " mbx)
;; We lie about high/low article number
(insert (format "%s 0 1 y\n" mbx)))))
- (gnus-message 5 "Generating active list for %s...done" server))
+ (gnus-message 5 "nnimap: Generating active list for %s...done" server))
t))
(deffoo nnimap-request-post (&optional server)
@@ -635,7 +632,7 @@
(when (nnimap-possibly-change-group group server)
(with-current-buffer nnimap-server-buffer
(let (action)
- (gnus-message 7 "Setting marks in %s:%s..."
+ (gnus-message 7 "nnimap: Setting marks in %s:%s..."
(nnoo-current-server 'nnimap) group)
(while (setq action (pop actions))
(let ((range (nth 0 action))
@@ -666,7 +663,7 @@
(imap-message-flags-set
(nnimap-range-to-string range)
(nnimap-mark-to-flag marks nil t)))))))
- (gnus-message 7 "Setting marks in %s:%s...done"
+ (gnus-message 7 "nnimap: Setting marks in %s:%s...done"
(nnoo-current-server 'nnimap) group))))
nil)
@@ -769,7 +766,7 @@
date)))
(defun nnimap-request-expire-articles-progress ()
- (gnus-message 5 "Expiring; marking article %d for deletion..."
+ (gnus-message 5 "nnimap: Marking article %d for deletion..."
imap-current-message))
;; Notice that we don't actually delete anything, we just mark them deleted.
Index: nnimap/ssl.el
diff -u nnimap/ssl.el:1.1 nnimap/ssl.el:1.2
--- nnimap/ssl.el:1.1 Fri Mar 26 14:07:07 1999
+++ nnimap/ssl.el Sun Jun 13 03:11:36 1999
@@ -1,7 +1,7 @@
;;; ssl.el,v --- ssl functions for emacsen without them builtin
;; Author: $Author: jas $
-;; Created: $Date: 2002/10/01 14:19:52 $
-;; Version: $Revision: 1.1 $
+;; Created: $Date: 2002/10/01 14:19:52 $
+;; Version: $Revision: 1.1 $
;; Keywords: comm
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;