From: Shenghuo ZHU <zsh@cs.rochester.edu>
Subject: Re: strange behaviour when `B c'ing an empty article
Date: 06 Oct 1999 23:20:37 -0400 [thread overview]
Message-ID: <5bvh8jonzu.fsf@giga.cs.rochester.edu> (raw)
In-Reply-To: Dan Christensen's message of "Wed, 06 Oct 1999 20:26:11 -0400"
[-- Attachment #1: Type: text/plain, Size: 562 bytes --]
>>>>> "Dan" == Dan Christensen <jdc@jhu.edu> writes:
Dan> I don't see any change in the behaviour.
The change is that 'B m' works.
Now, another patch make more things work. (Committed)
(Now, it's time to remove my a bunch of test nnfolder.)
--
Shenghuo ZHU
1999-10-06 Shenghuo ZHU <zsh@cs.rochester.edu>
* nnfolder.el (nnfolder-request-move-article): For empty article,
search till (point-max).
(nnfolder-retrieve-headers): Ditto.
(nnfolder-request-accept-article): Ditto.
(nnfolder-save-mail): Ditto.
(nnfolder-insert-newsgroup-line): Ditto.
[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: 97-107.diff --]
[-- Type: text/x-patch, Size: 2204 bytes --]
Index: nnfolder.el
===================================================================
RCS file: /usr/local/cvsroot/gnus/lisp/nnfolder.el,v
retrieving revision 5.19
diff -u -r5.19 nnfolder.el
--- nnfolder.el 1999/10/06 23:23:20 5.19
+++ nnfolder.el 1999/10/07 03:14:29
@@ -119,8 +119,9 @@
(set-buffer nnfolder-current-buffer)
(when (nnfolder-goto-article article)
(setq start (point))
- (search-forward "\n\n" nil t)
- (setq stop (1- (point)))
+ (setq stop (if (search-forward "\n\n" nil t)
+ (1- (point))
+ (point-max)))
(set-buffer nntp-server-buffer)
(insert (format "221 %d Article retrieved.\n" article))
(insert-buffer-substring nnfolder-current-buffer start stop)
@@ -401,8 +402,9 @@
(save-excursion
(set-buffer buf)
(goto-char (point-min))
- (search-forward "\n\n" nil t)
- (forward-line -1)
+ (if (search-forward "\n\n" nil t)
+ (forward-line -1)
+ (goto-char (point-max)))
(while (re-search-backward (concat "^" nnfolder-article-marker) nil t)
(delete-region (point) (progn (forward-line 1) (point))))
(when nnmail-cache-accepted-message-ids
@@ -648,8 +650,9 @@
(while (setq group-art (pop group-art-list))
;; Kill any previous newsgroup markers.
(goto-char (point-min))
- (search-forward "\n\n" nil t)
- (forward-line -1)
+ (if (search-forward "\n\n" nil t)
+ (forward-line -1)
+ (goto-char (point-max)))
(while (search-backward (concat "\n" nnfolder-article-marker) nil t)
(delete-region (1+ (point)) (progn (forward-line 2) (point))))
@@ -678,10 +681,11 @@
(defun nnfolder-insert-newsgroup-line (group-art)
(save-excursion
(goto-char (point-min))
- (when (search-forward "\n\n" nil t)
- (forward-char -1)
- (insert (format (concat nnfolder-article-marker "%d %s\n")
- (cdr group-art) (current-time-string))))))
+ (if (search-forward "\n\n" nil t)
+ (forward-char -1)
+ (goto-char (point-max)))
+ (insert (format (concat nnfolder-article-marker "%d %s\n")
+ (cdr group-art) (current-time-string)))))
(defun nnfolder-active-number (group)
;; Find the next article number in GROUP.
next prev parent reply other threads:[~1999-10-07 3:20 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
1999-10-06 20:57 Dan Christensen
1999-10-06 23:24 ` Shenghuo ZHU
1999-10-07 0:26 ` Dan Christensen
1999-10-07 3:20 ` Shenghuo ZHU [this message]
1999-10-07 5:07 ` Dan Christensen
1999-10-07 5:51 ` Shenghuo ZHU
1999-10-07 15:37 ` Dan Christensen
1999-10-07 21:15 ` Shenghuo ZHU
1999-10-07 21:44 ` Dan Christensen
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=5bvh8jonzu.fsf@giga.cs.rochester.edu \
--to=zsh@cs.rochester.edu \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
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).