Commit f4dd4ae8 authored by Miles Bader's avatar Miles Bader
Browse files

Revision: miles@gnu.org--gnu-2004/emacs--cvs-trunk--0--patch-575

Merge from gnus--rel--5.10

Patches applied:

 * miles@gnu.org--gnu-2004/gnus--rel--5.10--patch-34
   Merge from emacs--cvs-trunk--0

 * miles@gnu.org--gnu-2004/gnus--rel--5.10--patch-35
 - miles@gnu.org--gnu-2004/gnus--rel--5.10--patch-36
   Update from CVS
parent 6c1178b5
2004-09-27 Katsumi Yamaoka <yamaoka@jpl.org>
* mm-decode.el (mm-copy-to-buffer): Don't use set-buffer-multibyte.
2004-09-26 Jesper Harder <harder@ifa.au.dk>
* gnus-msg.el (gnus-post-news): Use blank Newsgroups line if
GROUP is a virtual group.
* mm-util.el (mm-charset-synonym-alist): Remove obsolete entries
for big5 and gb2312.
* rfc2047.el (rfc2047-pad-base64): Deal with more cases of invalid
padding.
* mm-bodies.el (mm-7bit-chars): Don't include \r.
* mml.el (mml-compute-boundary-1): Don't uncompress files.
* rfc2047.el (rfc2047-qp-or-base64): New function to reduce
dependencies.
(rfc2047-encode): Use it.
* flow-fill.el: Typo.
* mml.el (mml-generate-mime-1): Don't use format=flowed with
inline PGP.
* gnus.el (gnus-getenv-nntpserver): Strip whitespace.
* gnus-cache.el (gnus-cache-save-buffers): Check if buffer is
alive. Reported by Laurent Martelli <laurent@aopsys.com>.
* mm-util.el (mm-image-load-path): Handle nil in load-path.
From Christian Neukirchen <chneukirchen@yahoo.de>.
* html2text.el (html2text-replace-list): Add &amp; and &apos;.
* nnheader.el (nnheader-max-head-length): Increase to 8192.
* message.el (message-clone-locals): Clone sendmail and smtp
variables.
2004-09-23 Reiner Steib <Reiner.Steib@gmx.de>
* gnus-msg.el (gnus-configure-posting-styles): Narrow to headers
......
;;; flow-fill.el --- interprete RFC2646 "flowed" text
;;; flow-fill.el --- interpret RFC2646 "flowed" text
;; Copyright (C) 2000, 2001, 2002, 2003 Free Software Foundation, Inc.
......
......@@ -125,9 +125,8 @@ it's not cached."
(overview-file (gnus-cache-file-name
(car gnus-cache-buffer) ".overview")))
;; write the overview only if it was modified
(when (buffer-modified-p buffer)
(save-excursion
(set-buffer buffer)
(when (and (buffer-live-p buffer) (buffer-modified-p buffer))
(with-current-buffer buffer
(if (> (buffer-size) 0)
;; Non-empty overview, write it to a file.
(let ((coding-system-for-write
......
......@@ -915,7 +915,9 @@ header line with the old Message-ID."
(not to-address)))
;; This is news.
(if post
(message-news (or to-group group))
(message-news
(or to-group
(and (not (gnus-virtual-group-p pgroup)) group)))
(set-buffer gnus-article-copy)
(gnus-msg-treat-broken-reply-to)
(message-followup (if (or newsgroup-p force-news)
......
......@@ -1104,9 +1104,8 @@ Check the NNTPSERVER environment variable and the
(and (file-readable-p gnus-nntpserver-file)
(with-temp-buffer
(insert-file-contents gnus-nntpserver-file)
(let ((name (buffer-string)))
(unless (string-match "\\`[ \t\n]*$" name)
name))))))
(when (re-search-forward "[^ \t\n\r]+" nil t)
(match-string 0))))))
(defcustom gnus-select-method
(condition-case nil
......
;;; html2text.el --- a simple html to plain text converter
;; Copyright (C) 2002, 2003 Free Software Foundation, Inc.
;; Copyright (C) 2002, 2003, 2004 Free Software Foundation, Inc.
;; Author: Joakim Hove <hove@phys.ntnu.no>
......@@ -42,7 +42,8 @@
(defvar html2text-format-single-element-list '(("hr" . html2text-clean-hr)))
(defvar html2text-replace-list
'(("&nbsp;" . " ") ("&gt;" . ">") ("&lt;" . "<") ("&quot;" . "\""))
'(("&nbsp;" . " ") ("&gt;" . ">") ("&lt;" . "<") ("&quot;" . "\"")
("&amp;" . "&") ("&apos;" . "'"))
"The map of entity to text.
This is an alist were each element is a dotted pair consisting of an
......
......@@ -6685,7 +6685,7 @@ regexp VARSTR."
(let ((locals (save-excursion
(set-buffer buffer)
(buffer-local-variables)))
(regexp "^gnus\\|^nn\\|^message\\|^user-mail-address"))
(regexp "^gnus\\|^nn\\|^message\\|^sendmail\\|^smtp\\|^user-mail-address"))
(mapcar
(lambda (local)
(when (and (consp local)
......
......@@ -38,9 +38,16 @@
(require 'rfc2047)
(require 'mm-encode)
;; 8bit treatment gets any char except: 0x32 - 0x7f, CR, LF, TAB, BEL,
;; 8bit treatment gets any char except: 0x32 - 0x7f, LF, TAB, BEL,
;; BS, vertical TAB, form feed, and ^_
(defvar mm-7bit-chars "\x20-\x7f\r\n\t\x7\x8\xb\xc\x1f")
;;
;; Note that CR is *not* included, as that would allow a non-paired CR
;; in the body contrary to RFC 2822:
;;
;; - CR and LF MUST only occur together as CRLF; they MUST NOT
;; appear independently in the body.
(defvar mm-7bit-chars "\x20-\x7f\n\t\x7\x8\xb\xc\x1f")
(defcustom mm-body-charset-encoding-alist
'((iso-2022-jp . 7bit)
......
......@@ -623,14 +623,14 @@ Postpone undisplaying of viewers for types in
"Copy the contents of the current buffer to a fresh buffer."
(save-excursion
(let ((obuf (current-buffer))
(multibyte enable-multibyte-characters)
beg)
(goto-char (point-min))
(search-forward-regexp "^\n" nil t)
(setq beg (point))
(set-buffer (generate-new-buffer " *mm*"))
;; Preserve the data's unibyteness (for url-insert-file-contents).
(set-buffer-multibyte multibyte)
(set-buffer
;; Preserve the data's unibyteness (for url-insert-file-contents).
(let ((default-enable-multibyte-characters (mm-multibyte-p)))
(generate-new-buffer " *mm*")))
(insert-buffer-substring obuf beg)
(current-buffer))))
......
......@@ -133,15 +133,9 @@ In XEmacs, also return non-nil if CS is a coding system object."
(defvar mm-charset-synonym-alist
`(
;; Perfectly fine? A valid MIME name, anyhow.
,@(unless (mm-coding-system-p 'big5)
'((big5 . cn-big5)))
;; Not in XEmacs, but it's not a proper MIME charset anyhow.
,@(unless (mm-coding-system-p 'x-ctext)
'((x-ctext . ctext)))
;; Apparently not defined in Emacs 20, but is a valid MIME name.
,@(unless (mm-coding-system-p 'gb2312)
'((gb2312 . cn-gb-2312)))
;; ISO-8859-15 is very similar to ISO-8859-1. But it's _different_!
,@(unless (mm-coding-system-p 'iso-8859-15)
'((iso-8859-15 . iso-8859-1)))
......@@ -785,11 +779,12 @@ If INHIBIT is non-nil, inhibit `mm-inhibit-file-name-handlers'."
(defun mm-image-load-path (&optional package)
(let (dir result)
(dolist (path load-path (nreverse result))
(if (file-directory-p
(setq dir (concat (file-name-directory
(directory-file-name path))
"etc/" (or package "gnus/"))))
(push dir result))
(when (and path
(file-directory-p
(setq dir (concat (file-name-directory
(directory-file-name path))
"etc/" (or package "gnus/")))))
(push dir result))
(push path result))))
;; Fixme: This doesn't look useful where it's used.
......
......@@ -450,6 +450,7 @@ If MML is non-nil, return the buffer up till the correspondent mml tag."
;; actually are hard newlines in the text.
(let (use-hard-newlines)
(when (and (string= type "text/plain")
(not (string= (cdr (assq 'sign cont)) "pgp"))
(or (null (assq 'format cont))
(string= (cdr (assq 'format cont))
"flowed"))
......@@ -591,7 +592,7 @@ If MML is non-nil, return the buffer up till the correspondent mml tag."
(insert-buffer-substring (cdr (assq 'buffer cont))))
((and (setq filename (cdr (assq 'filename cont)))
(not (equal (cdr (assq 'nofile cont)) "yes")))
(mm-insert-file-contents filename))
(mm-insert-file-contents filename nil nil nil nil t))
(t
(insert (cdr (assq 'contents cont)))))
(goto-char (point-min))
......
;;; nnheader.el --- header access macros for Gnus and its backends
;; Copyright (C) 1987, 1988, 1989, 1990, 1993, 1994, 1995, 1996,
;; 1997, 1998, 2000, 2001, 2002, 2003
;; 1997, 1998, 2000, 2001, 2002, 2003, 2004
;; Free Software Foundation, Inc.
;; Author: Masanobu UMEDA <umerin@flab.flab.fujitsu.junet>
......@@ -58,7 +58,7 @@ they will keep on jabbering all the time."
:group 'gnus-server
:type 'boolean)
(defvar nnheader-max-head-length 4096
(defvar nnheader-max-head-length 8192
"*Max length of the head of articles.
Value is an integer, nil, or t. nil means read in chunks of a file
......
......@@ -126,6 +126,25 @@ quoted-printable and base64 respectively.")
;;; Functions for encoding RFC2047 messages
;;;
(defun rfc2047-qp-or-base64 ()
"Return the type with which to encode the buffer.
This is either `base64' or `quoted-printable'."
(save-excursion
(let ((limit (min (point-max) (+ 2000 (point-min))))
(n8bit 0))
(goto-char (point-min))
(skip-chars-forward "\x20-\x7f\r\n\t" limit)
(while (< (point) limit)
(incf n8bit)
(forward-char 1)
(skip-chars-forward "\x20-\x7f\r\n\t" limit))
(if (or (< (* 6 n8bit) (- limit (point-min)))
;; Don't base64, say, a short line with a single
;; non-ASCII char when splitting parts by charset.
(= n8bit 1))
'quoted-printable
'base64))))
(defun rfc2047-narrow-to-field ()
"Narrow the buffer to the header on the current line."
(beginning-of-line)
......@@ -411,7 +430,7 @@ By default, the region is treated as containing addresses (see
;; encoding, choose the one that's shorter.
(save-restriction
(narrow-to-region b e)
(if (eq (mm-qp-or-base64) 'base64)
(if (eq (rfc2047-qp-or-base64) 'base64)
'B
'Q))))
(start (concat
......@@ -720,11 +739,15 @@ decodable."
;; Be more liberal to accept buggy base64 strings. If
;; base64-decode-string accepts buggy strings, this function could
;; be aliased to identity.
(case (mod (length string) 4)
(0 string)
(1 string) ;; Error, don't pad it.
(2 (concat string "=="))
(3 (concat string "="))))
(if (= 0 (mod (length string) 4))
string
(when (string-match "=+$" string)
(setq string (substring string 0 (match-beginning 0))))
(case (mod (length string) 4)
(0 string)
(1 string) ;; Error, don't pad it.
(2 (concat string "=="))
(3 (concat string "=")))))
(defun rfc2047-decode (charset encoding string)
"Decode STRING from the given MIME CHARSET in the given ENCODING.
......
2004-09-26 Jesper Harder <harder@ifa.au.dk>
* sieve.texi (Manage Sieve API): nil -> @code{nil}.
* pgg.texi (User Commands, Backend methods): do.
* gnus.texi: Markup fixes.
(Setting Process Marks): Fix `M P a' entry.
* emacs-mime: Fixes.
2004-09-23 Reiner Steib <Reiner.Steib@gmx.de>
* gnus-faq.texi ([5.12]): Fix code example for FQDN in Message-Ids
......
......@@ -328,7 +328,7 @@ you could say something like:
@item mm-inline-large-images
@vindex mm-inline-large-images
When displaying inline images that are larger than the window, XEmacs
When displaying inline images that are larger than the window, Emacs
does not enable scrolling, which means that you cannot see the whole
image. To prevent this, the library tries to determine the image size
before displaying it inline, and if it doesn't fit the window, the
......
......@@ -6206,7 +6206,7 @@ Mark all series that have already had some articles marked
@item M P a
@kindex M P a (Summary)
@findex gnus-uu-mark-all
Mark all articles in series order (@code{gnus-uu-mark-series}).
Mark all articles in series order (@code{gnus-uu-mark-all}).
 
@item M P b
@kindex M P b (Summary)
......@@ -16625,7 +16625,7 @@ follows:
This instructs the @code{imap.el} package to log any exchanges with
the server. The log is stored in the buffer @samp{*imap-log*}. Look
for error messages, which sometimes are tagged with the keyword
@code{BAD} - but when submitting a bug, make sure to include all the
@code{BAD}---but when submitting a bug, make sure to include all the
data.
 
@node Other Sources
......@@ -18300,8 +18300,8 @@ placeholders if you care (See @code{gnus-auto-goto-ignores}).
While it may be obvious to all, the only headers and articles
available while unplugged are those headers and articles that were
fetched into the Agent while previously plugged. To put it another
way, "If you forget to fetch something while plugged, you might have a
less than satisfying unplugged session". For this reason, the Agent
way, ``If you forget to fetch something while plugged, you might have a
less than satisfying unplugged session''. For this reason, the Agent
adds two visual effects to your summary buffer. These effects display
the download status of each article so that you always know which
articles will be available when unplugged.
......@@ -20490,8 +20490,8 @@ something like:
...
@end example
 
Then that means "score on the from header of the grandparent of the
current article". An indirection is quite fast, but it's better to say:
Then that means ``score on the from header of the grandparent of the
current article''. An indirection is quite fast, but it's better to say:
 
@example
(1-
......@@ -22710,7 +22710,7 @@ entering a group. Thus, entering a group with unseen or unread
articles becomes the substitute for checking incoming mail. Whether
only unseen articles or all unread articles will be processed is
determined by the @code{spam-autodetect-recheck-messages}. When set
to t, unread messages will be rechecked.
to @code{t}, unread messages will be rechecked.
 
@code{spam-autodetect} grants the user at once more and less control
of spam filtering. The user will have more control over each group's
......
......@@ -135,8 +135,9 @@ would be asked about the recipients.
If encryption is successful, it replaces the current region contents (in
the accessible portion) with the resulting data.
If optional argument @var{sign} is non-nil, the function is request to
do a combined sign and encrypt. This currently only work with GnuPG.
If optional argument @var{sign} is non-@code{nil}, the function is
request to do a combined sign and encrypt. This currently only work
with GnuPG.
@end deffn
@deffn Command pgg-decrypt-region start end
......@@ -301,9 +302,9 @@ keyrings.
@deffn Method pgg-scheme-encrypt-region scheme start end recipients &optional sign
Encrypt the current region between @var{start} and @var{end} for
@var{recipients}. If @var{sign} is non-nil, do a combined sign and
encrypt. If encryption is successful, it returns @code{t}, otherwise
@code{nil}.
@var{recipients}. If @var{sign} is non-@code{nil}, do a combined sign
and encrypt. If encryption is successful, it returns @code{t},
otherwise @code{nil}.
@end deffn
@deffn Method pgg-scheme-decrypt-region scheme start end
......
......@@ -277,7 +277,7 @@ Sets the default port to use, the suggested port number is @code{2000}.
@item sieve-manage-log
@vindex sieve-manage-log
If non-nil, should be a string naming a buffer where a protocol trace
If non-@code{nil}, should be a string naming a buffer where a protocol trace
is dumped (for debugging purposes).
@end table
......@@ -313,7 +313,8 @@ List scripts on the server.
@item sieve-manage-havespace
@findex sieve-manage-havespace
Returns non-nil iff server have roam for a script of given size.
Returns non-@code{nil} iff server have roam for a script of given
size.
@item sieve-manage-getscript
@findex sieve-manage-getscript
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment