From: yamaoka Date: Sun, 15 Apr 2001 22:41:29 +0000 (+0000) Subject: This commit was generated by cvs2svn to compensate for changes in r4526, X-Git-Url: http://git.chise.org/gitweb/?a=commitdiff_plain;h=0ea8c9d5432fedda0c6cb14bb6e60068df046545;hp=5bea01c24529e46295793d2b5dae5d7dea171d30;p=elisp%2Fgnus.git- This commit was generated by cvs2svn to compensate for changes in r4526, which included commits to RCS files with non-trunk default branches. --- diff --git a/.cvsignore b/.cvsignore new file mode 100644 index 0000000..9c59f23 --- /dev/null +++ b/.cvsignore @@ -0,0 +1,8 @@ +Makefile +config.cache +config.log +config.status +diff-lisp.el +diffit +makepub +cvs-access diff --git a/README b/README index 5104634..b8d2527 100644 --- a/README +++ b/README @@ -1,4 +1,4 @@ -This package contains a beta version of Gnus. The lisp directory +This package contains a alpha version of Gnus. The lisp directory contains the source lisp files, and the texi directory contains a draft of the Gnus info pages. diff --git a/aclocal.m4 b/aclocal.m4 index 2a7b8d0..1c11603 100644 --- a/aclocal.m4 +++ b/aclocal.m4 @@ -96,6 +96,17 @@ AC_DEFUN(AC_PATH_LISPDIR, [ AC_SUBST(lispdir) ]) +AC_DEFUN(AC_PATH_ETCDIR, [ + AC_ARG_WITH(etcdir,[ --with-etcdir=DIR Where to install etc files], etcdir=${withval}) + AC_MSG_CHECKING([where etc files should go]) + if test -z "$etcdir"; then + dnl Set default value + etcdir="\$(lispdir)/../etc" + fi + AC_MSG_RESULT($etcdir) + AC_SUBST(etcdir) +]) + dnl dnl Check whether a function exists in a library dnl All '_' characters in the first argument are converted to '-' @@ -142,3 +153,27 @@ fi AC_SUBST(W3) AC_MSG_RESULT("${W3}") ]) + +dnl +dnl Perform sanity checking and try to locate the W3 package +dnl +AC_DEFUN(AC_CHECK_URL, [ +AC_MSG_CHECKING(for acceptable URL version) +AC_CACHE_VAL(EMACS_cv_ACCEPTABLE_URL,[ +AC_EMACS_CHECK_LIB(url, url-retrieve, "noecho") +if test "${HAVE_url}" = "yes"; then + EMACS_cv_ACCEPTABLE_URL=yes +else + EMACS_cv_ACCEPTABLE_URL=no +fi + +if test "${EMACS_cv_ACCEPTABLE_URL}" = "yes"; then + AC_EMACS_LISP(url_dir,(file-name-directory (locate-library \"url\")),"noecho") + EMACS_cv_ACCEPTABLE_URL=$EMACS_cv_SYS_url_dir +fi +]) + AC_ARG_WITH(url,[ --with-url=DIR Specify where to find the url package], [ EMACS_cv_ACCEPTABLE_URL=`( cd $withval && pwd || echo "$withval" ) 2> /dev/null` ]) + URL=${EMACS_cv_ACCEPTABLE_URL} + AC_SUBST(URL) + AC_MSG_RESULT("${URL}") +]) diff --git a/configure b/configure index 66b39e6..dfe4746 100755 --- a/configure +++ b/configure @@ -1,7 +1,7 @@ #! /bin/sh # Guess values for system-dependent variables and create Makefiles. -# Generated automatically using autoconf version 2.12 +# Generated automatically using autoconf version 2.13 # Copyright (C) 1992, 93, 94, 95, 96 Free Software Foundation, Inc. # # This configure script is free software; the Free Software Foundation @@ -18,6 +18,10 @@ ac_help="$ac_help ac_help="$ac_help --with-lispdir=DIR Where to install lisp files" ac_help="$ac_help + --with-etcdir=DIR Where to install etc files" +ac_help="$ac_help + --with-url=DIR Specify where to find the url package" +ac_help="$ac_help --with-w3=DIR Specify where to find the w3 package" # Initialize some variables set by options. @@ -57,6 +61,7 @@ mandir='${prefix}/man' # Initialize some other variables. subdirs= MFLAGS= MAKEFLAGS= +SHELL=${CONFIG_SHELL-/bin/sh} # Maximum number of lines to put in a shell here document. ac_max_here_lines=12 @@ -340,7 +345,7 @@ EOF verbose=yes ;; -version | --version | --versio | --versi | --vers) - echo "configure generated by autoconf version 2.12" + echo "configure generated by autoconf version 2.13" exit 0 ;; -with-* | --with-*) @@ -510,9 +515,11 @@ ac_ext=c # CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options. ac_cpp='$CPP $CPPFLAGS' ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5' -ac_link='${CC-cc} -o conftest $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5' +ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5' cross_compiling=$ac_cv_prog_cc_cross +ac_exeext= +ac_objext=o if (echo "testing\c"; echo 1,2,3) | grep c >/dev/null; then # Stardent Vistra SVR4 grep lacks -e, says ghazi@caip.rutgers.edu. if (echo -n testing; echo 1,2,3) | sed s/-n/xn/ | grep xn >/dev/null; then @@ -527,7 +534,7 @@ fi echo $ac_n "checking whether ${MAKE-make} sets \${MAKE}""... $ac_c" 1>&6 -echo "configure:531: checking whether ${MAKE-make} sets \${MAKE}" >&5 +echo "configure:538: checking whether ${MAKE-make} sets \${MAKE}" >&5 set dummy ${MAKE-make}; ac_make=`echo "$2" | sed 'y%./+-%__p_%'` if eval "test \"`echo '$''{'ac_cv_prog_make_${ac_make}_set'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 @@ -579,28 +586,30 @@ ac_configure=$ac_aux_dir/configure # This should be Cygnus configure. # SunOS /usr/etc/install # IRIX /sbin/install # AIX /bin/install +# AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag # AFS /usr/afsws/bin/install, which mishandles nonexistent args # SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff" # ./install, which can be erroneously created by make from ./install.sh. echo $ac_n "checking for a BSD compatible install""... $ac_c" 1>&6 -echo "configure:587: checking for a BSD compatible install" >&5 +echo "configure:595: checking for a BSD compatible install" >&5 if test -z "$INSTALL"; then if eval "test \"`echo '$''{'ac_cv_path_install'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else - IFS="${IFS= }"; ac_save_IFS="$IFS"; IFS="${IFS}:" + IFS="${IFS= }"; ac_save_IFS="$IFS"; IFS=":" for ac_dir in $PATH; do # Account for people who put trailing slashes in PATH elements. case "$ac_dir/" in /|./|.//|/etc/*|/usr/sbin/*|/usr/etc/*|/sbin/*|/usr/afsws/bin/*|/usr/ucb/*) ;; *) # OSF1 and SCO ODT 3.0 have their own names for install. - for ac_prog in ginstall installbsd scoinst install; do + # Don't use installbsd from OSF since it installs stuff as root + # by default. + for ac_prog in ginstall scoinst install; do if test -f $ac_dir/$ac_prog; then if test $ac_prog = install && grep dspmsg $ac_dir/$ac_prog >/dev/null 2>&1; then # AIX install. It has an incompatible calling convention. - # OSF/1 installbsd also uses dspmsg, but is usable. : else ac_cv_path_install="$ac_dir/$ac_prog -c" @@ -630,6 +639,8 @@ echo "$ac_t""$INSTALL" 1>&6 # It thinks the first close brace ends the variable substitution. test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}' +test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL_PROGRAM}' + test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644' @@ -652,15 +663,16 @@ fi # Extract the first word of "makeinfo", so it can be a program name with args. set dummy makeinfo; ac_word=$2 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 -echo "configure:656: checking for $ac_word" >&5 +echo "configure:667: checking for $ac_word" >&5 if eval "test \"`echo '$''{'ac_cv_prog_MAKEINFO'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else if test -n "$MAKEINFO"; then ac_cv_prog_MAKEINFO="$MAKEINFO" # Let the user override the test. else - IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:" - for ac_dir in $PATH; do + IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":" + ac_dummy="$PATH" + for ac_dir in $ac_dummy; do test -z "$ac_dir" && ac_dir=. if test -f $ac_dir/$ac_word; then ac_cv_prog_MAKEINFO="makeinfo" @@ -682,15 +694,16 @@ fi # Extract the first word of "emacs", so it can be a program name with args. set dummy emacs; ac_word=$2 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 -echo "configure:686: checking for $ac_word" >&5 +echo "configure:698: checking for $ac_word" >&5 if eval "test \"`echo '$''{'ac_cv_prog_EMACS'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else if test -n "$EMACS"; then ac_cv_prog_EMACS="$EMACS" # Let the user override the test. else - IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:" - for ac_dir in $PATH; do + IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":" + ac_dummy="$PATH" + for ac_dir in $ac_dummy; do test -z "$ac_dir" && ac_dir=. if test -f $ac_dir/$ac_word; then ac_cv_prog_EMACS="emacs" @@ -712,12 +725,12 @@ fi echo $ac_n "checking if $EMACS is really XEmacs""... $ac_c" 1>&6 -echo "configure:716: checking if $EMACS is really XEmacs" >&5 +echo "configure:729: checking if $EMACS is really XEmacs" >&5 elisp="(if (string-match \"XEmacs\" emacs-version) \"yes\" \"no\") " if test -z ""noecho""; then echo $ac_n "checking for xemacsp""... $ac_c" 1>&6 -echo "configure:721: checking for xemacsp" >&5 +echo "configure:734: checking for xemacsp" >&5 fi if eval "test \"`echo '$''{'EMACS_cv_SYS_xemacsp'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 @@ -749,12 +762,12 @@ fi if test "$prefix" = "NONE"; then echo $ac_n "checking prefix for your Emacs""... $ac_c" 1>&6 -echo "configure:753: checking prefix for your Emacs" >&5 +echo "configure:766: checking prefix for your Emacs" >&5 elisp="(expand-file-name \"..\" invocation-directory)" if test -z ""noecho""; then echo $ac_n "checking for prefix""... $ac_c" 1>&6 -echo "configure:758: checking for prefix" >&5 +echo "configure:771: checking for prefix" >&5 fi if eval "test \"`echo '$''{'EMACS_cv_SYS_prefix'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 @@ -785,7 +798,7 @@ if test "${with_lispdir+set}" = set; then fi echo $ac_n "checking where .elc files should go""... $ac_c" 1>&6 -echo "configure:789: checking where .elc files should go" >&5 +echo "configure:802: checking where .elc files should go" >&5 if test -z "$lispdir"; then theprefix=$prefix if test "x$theprefix" = "xNONE"; then @@ -804,8 +817,120 @@ echo "configure:789: checking where .elc files should go" >&5 + # Check whether --with-etcdir or --without-etcdir was given. +if test "${with_etcdir+set}" = set; then + withval="$with_etcdir" + etcdir=${withval} +fi + + echo $ac_n "checking where etc files should go""... $ac_c" 1>&6 +echo "configure:828: checking where etc files should go" >&5 + if test -z "$etcdir"; then + etcdir="\$(lispdir)/../etc" + fi + echo "$ac_t""$etcdir" 1>&6 + + + +echo $ac_n "checking for acceptable URL version""... $ac_c" 1>&6 +echo "configure:837: checking for acceptable URL version" >&5 +if eval "test \"`echo '$''{'EMACS_cv_ACCEPTABLE_URL'+set}'`\" = set"; then + echo $ac_n "(cached) $ac_c" 1>&6 +else + + +if test -z ""noecho""; then + echo $ac_n "checking for url-retrieve in url""... $ac_c" 1>&6 +echo "configure:845: checking for url-retrieve in url" >&5 +fi +library=`echo url | tr _ -` + +elisp="(progn (fmakunbound 'url-retrieve) (condition-case nil (progn (require '$library) (fboundp 'url-retrieve)) (error (prog1 nil (message \"$library not found\")))))" +if test -z ""noecho""; then + echo $ac_n "checking for url""... $ac_c" 1>&6 +echo "configure:852: checking for url" >&5 +fi +if eval "test \"`echo '$''{'EMACS_cv_SYS_url'+set}'`\" = set"; then + echo $ac_n "(cached) $ac_c" 1>&6 +else + + OUTPUT=./conftest-$$ + echo ${EMACS} -batch -eval "(let ((x ${elisp})) (write-region (if (stringp x) (princ x) (prin1-to-string x)) nil \"${OUTPUT}\"))" >& 5 2>&1 + ${EMACS} -batch -eval "(let ((x ${elisp})) (write-region (if (stringp x) (princ x 'ignore) (prin1-to-string x)) nil \"${OUTPUT}\"nil 5))" >& 5 2>&1 + retval=`cat ${OUTPUT}` + echo "=> ${retval}" >& 5 2>&1 + rm -f ${OUTPUT} + EMACS_cv_SYS_url=$retval + +fi + +url=${EMACS_cv_SYS_url} +if test -z ""noecho""; then + echo "$ac_t""$url" 1>&6 +fi + +if test "${EMACS_cv_SYS_url}" = "nil"; then + EMACS_cv_SYS_url=no +fi +if test "${EMACS_cv_SYS_url}" = "t"; then + EMACS_cv_SYS_url=yes +fi +HAVE_url=${EMACS_cv_SYS_url} + +if test -z ""noecho""; then + echo "$ac_t""$HAVE_url" 1>&6 +fi + +if test "${HAVE_url}" = "yes"; then + EMACS_cv_ACCEPTABLE_URL=yes +else + EMACS_cv_ACCEPTABLE_URL=no +fi + +if test "${EMACS_cv_ACCEPTABLE_URL}" = "yes"; then + +elisp="(file-name-directory (locate-library \"url\"))" +if test -z ""noecho""; then + echo $ac_n "checking for url_dir""... $ac_c" 1>&6 +echo "configure:896: checking for url_dir" >&5 +fi +if eval "test \"`echo '$''{'EMACS_cv_SYS_url_dir'+set}'`\" = set"; then + echo $ac_n "(cached) $ac_c" 1>&6 +else + + OUTPUT=./conftest-$$ + echo ${EMACS} -batch -eval "(let ((x ${elisp})) (write-region (if (stringp x) (princ x) (prin1-to-string x)) nil \"${OUTPUT}\"))" >& 5 2>&1 + ${EMACS} -batch -eval "(let ((x ${elisp})) (write-region (if (stringp x) (princ x 'ignore) (prin1-to-string x)) nil \"${OUTPUT}\"nil 5))" >& 5 2>&1 + retval=`cat ${OUTPUT}` + echo "=> ${retval}" >& 5 2>&1 + rm -f ${OUTPUT} + EMACS_cv_SYS_url_dir=$retval + +fi + +url_dir=${EMACS_cv_SYS_url_dir} +if test -z ""noecho""; then + echo "$ac_t""$url_dir" 1>&6 +fi + + EMACS_cv_ACCEPTABLE_URL=$EMACS_cv_SYS_url_dir +fi + +fi + + # Check whether --with-url or --without-url was given. +if test "${with_url+set}" = set; then + withval="$with_url" + EMACS_cv_ACCEPTABLE_URL=`( cd $withval && pwd || echo "$withval" ) 2> /dev/null` +fi + + URL=${EMACS_cv_ACCEPTABLE_URL} + + echo "$ac_t"""${URL}"" 1>&6 + + echo $ac_n "checking for acceptable W3 version""... $ac_c" 1>&6 -echo "configure:809: checking for acceptable W3 version" >&5 +echo "configure:934: checking for acceptable W3 version" >&5 if eval "test \"`echo '$''{'EMACS_cv_ACCEPTABLE_W3'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else @@ -813,14 +938,14 @@ else if test -z ""noecho""; then echo $ac_n "checking for w3-form-encode-xwfu in w3_forms""... $ac_c" 1>&6 -echo "configure:817: checking for w3-form-encode-xwfu in w3_forms" >&5 +echo "configure:942: checking for w3-form-encode-xwfu in w3_forms" >&5 fi library=`echo w3_forms | tr _ -` elisp="(progn (fmakunbound 'w3-form-encode-xwfu) (condition-case nil (progn (require '$library) (fboundp 'w3-form-encode-xwfu)) (error (prog1 nil (message \"$library not found\")))))" if test -z ""noecho""; then echo $ac_n "checking for w3_forms""... $ac_c" 1>&6 -echo "configure:824: checking for w3_forms" >&5 +echo "configure:949: checking for w3_forms" >&5 fi if eval "test \"`echo '$''{'EMACS_cv_SYS_w3_forms'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 @@ -864,7 +989,7 @@ if test "${EMACS_cv_ACCEPTABLE_W3}" = "yes"; then elisp="(file-name-directory (locate-library \"w3-forms\"))" if test -z ""noecho""; then echo $ac_n "checking for w3_dir""... $ac_c" 1>&6 -echo "configure:868: checking for w3_dir" >&5 +echo "configure:993: checking for w3_dir" >&5 fi if eval "test \"`echo '$''{'EMACS_cv_SYS_w3_dir'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 @@ -924,7 +1049,7 @@ EOF # Ultrix sh set writes to stderr and can't be redirected directly, # and sets the high bit in the cache file unless we assign to the vars. (set) 2>&1 | - case `(ac_space=' '; set) 2>&1` in + case `(ac_space=' '; set | grep ac_space) 2>&1` in *ac_space=\ *) # `set' does not quote correctly, so add quotes (double-quote substitution # turns \\\\ into \\, and sed turns \\ into \). @@ -1003,7 +1128,7 @@ do echo "running \${CONFIG_SHELL-/bin/sh} $0 $ac_configure_args --no-create --no-recursion" exec \${CONFIG_SHELL-/bin/sh} $0 $ac_configure_args --no-create --no-recursion ;; -version | --version | --versio | --versi | --vers | --ver | --ve | --v) - echo "$CONFIG_STATUS generated by autoconf version 2.12" + echo "$CONFIG_STATUS generated by autoconf version 2.13" exit 0 ;; -help | --help | --hel | --he | --h) echo "\$ac_cs_usage"; exit 0 ;; @@ -1014,7 +1139,7 @@ done ac_given_srcdir=$srcdir ac_given_INSTALL="$INSTALL" -trap 'rm -fr `echo "Makefile lisp/Makefile texi/Makefile" | sed "s/:[^ ]*//g"` conftest*; exit 1' 1 2 15 +trap 'rm -fr `echo "Makefile lisp/Makefile texi/Makefile etc/Makefile" | sed "s/:[^ ]*//g"` conftest*; exit 1' 1 2 15 EOF cat >> $CONFIG_STATUS < conftest.subs <<\\CEOF $ac_vpsub $extrasub +s%@SHELL@%$SHELL%g s%@CFLAGS@%$CFLAGS%g s%@CPPFLAGS@%$CPPFLAGS%g s%@CXXFLAGS@%$CXXFLAGS%g +s%@FFLAGS@%$FFLAGS%g s%@DEFS@%$DEFS%g s%@LDFLAGS@%$LDFLAGS%g s%@LIBS@%$LIBS%g @@ -1046,12 +1173,16 @@ s%@infodir@%$infodir%g s%@mandir@%$mandir%g s%@SET_MAKE@%$SET_MAKE%g s%@INSTALL_PROGRAM@%$INSTALL_PROGRAM%g +s%@INSTALL_SCRIPT@%$INSTALL_SCRIPT%g s%@INSTALL_DATA@%$INSTALL_DATA%g s%@MAKEINFO@%$MAKEINFO%g s%@EMACS@%$EMACS%g s%@XEMACS@%$XEMACS%g s%@EMACS_FLAVOR@%$EMACS_FLAVOR%g s%@lispdir@%$lispdir%g +s%@etcdir@%$etcdir%g +s%@HAVE_url@%$HAVE_url%g +s%@URL@%$URL%g s%@HAVE_w3_forms@%$HAVE_w3_forms%g s%@W3@%$W3%g @@ -1095,7 +1226,7 @@ EOF cat >> $CONFIG_STATUS <> $CONFIG_STATUS <<\EOF for ac_file in .. $CONFIG_FILES; do if test "x$ac_file" != x..; then diff --git a/configure.in b/configure.in index a3610f6..3600414 100644 --- a/configure.in +++ b/configure.in @@ -19,6 +19,8 @@ AC_CHECK_PROG(MAKEINFO, makeinfo, makeinfo, no) AC_CHECK_PROG(EMACS, emacs, emacs, xemacs) AC_PATH_LISPDIR +AC_PATH_ETCDIR +AC_CHECK_URL AC_CHECK_W3 -AC_OUTPUT(Makefile lisp/Makefile texi/Makefile) +AC_OUTPUT(Makefile lisp/Makefile texi/Makefile etc/Makefile) diff --git a/contrib/.cvsignore b/contrib/.cvsignore new file mode 100644 index 0000000..944a7e8 --- /dev/null +++ b/contrib/.cvsignore @@ -0,0 +1,2 @@ +gnus-mdrtn.el +on-loginfo diff --git a/etc/.cvsignore b/etc/.cvsignore new file mode 100644 index 0000000..7a03f3f --- /dev/null +++ b/etc/.cvsignore @@ -0,0 +1,4 @@ +gnus +message +smilies +sounds diff --git a/lisp/.cvsignore b/lisp/.cvsignore new file mode 100644 index 0000000..22fc52c --- /dev/null +++ b/lisp/.cvsignore @@ -0,0 +1,4 @@ +Makefile +version +*.elc +gnus-load.el diff --git a/lisp/gnus-audio.el b/lisp/gnus-audio.el index ac959e7..8906745 100644 --- a/lisp/gnus-audio.el +++ b/lisp/gnus-audio.el @@ -32,6 +32,7 @@ (defgroup gnus-audio nil "Playing sound in Gnus." + :version "21.1" :group 'gnus-visual :group 'multimedia) diff --git a/lisp/gnus-cite.el b/lisp/gnus-cite.el index 8bca531..73c4bef 100644 --- a/lisp/gnus-cite.el +++ b/lisp/gnus-cite.el @@ -31,6 +31,7 @@ (require 'gnus) (require 'gnus-art) (require 'gnus-range) +(require 'message) ; for message-cite-prefix-regexp ;;; Customization: @@ -79,19 +80,13 @@ Set it to nil to parse all articles." :type '(choice (const :tag "all" nil) integer)) -(defcustom gnus-cite-prefix-regexp - "^[]>»|:}+ ]*[]>»|:}+]\\(.*>»\\)?\\|^.*>" - "*Regexp matching the longest possible citation prefix on a line." - :group 'gnus-cite - :type 'regexp) - (defcustom gnus-cite-max-prefix 20 "Maximum possible length for a citation prefix." :group 'gnus-cite :type 'integer) (defcustom gnus-supercite-regexp - (concat "^\\(" gnus-cite-prefix-regexp "\\)? *" + (concat "^\\(" message-cite-prefix-regexp "\\)? *" ">>>>> +\"\\([^\"\n]+\\)\" +==") "*Regexp matching normal Supercite attribution lines. The first grouping must match prefixes added by other packages." @@ -311,7 +306,7 @@ Attribution lines are highlighted with the same face as the corresponding citation merged with `gnus-cite-attribution-face'. Text is considered cited if at least `gnus-cite-minimum-match-count' -lines matches `gnus-cite-prefix-regexp' with the same prefix. +lines matches `message-cite-prefix-regexp' with the same prefix. Lines matching `gnus-cite-attribution-suffix' and perhaps `gnus-cite-attribution-prefix' are considered attribution lines." @@ -444,7 +439,9 @@ If WIDTH (the numerical prefix), use that text width when filling." (narrow-to-region (caar marks) (caadr marks)) (let ((adaptive-fill-regexp (concat "^" (regexp-quote (cdar marks)) " *")) - (fill-prefix (cdar marks))) + (fill-prefix + (if (string= (cdar marks) "") "" + (concat (cdar marks) " ")))) (fill-region (point-min) (point-max))) (set-marker (caar marks) nil) (setq marks (cdr marks))) @@ -683,23 +680,26 @@ See also the documentation for `gnus-article-highlight-citation'." (goto-char (point-max)) (gnus-article-search-signature) (point))) - alist entry start begin end numbers prefix) + (prefix-regexp (concat "^\\(" message-cite-prefix-regexp "\\)")) + alist entry start begin end numbers prefix guess-limit) ;; Get all potential prefixes in `alist'. (while (< (point) max) ;; Each line. (setq begin (point) + guess-limit (progn (skip-chars-forward "^> \t\r\n") (point)) end (progn (beginning-of-line 2) (point)) start end) (goto-char begin) ;; Ignore standard Supercite attribution prefix. - (when (looking-at gnus-supercite-regexp) + (when (and (< guess-limit (+ begin gnus-cite-max-prefix)) + (looking-at gnus-supercite-regexp)) (if (match-end 1) (setq end (1+ (match-end 1))) (setq end (1+ begin)))) ;; Ignore very long prefixes. - (when (> end (+ (point) gnus-cite-max-prefix)) - (setq end (+ (point) gnus-cite-max-prefix))) - (while (re-search-forward gnus-cite-prefix-regexp (1- end) t) + (when (> end (+ begin gnus-cite-max-prefix)) + (setq end (+ begin gnus-cite-max-prefix))) + (while (re-search-forward prefix-regexp (1- end) t) ;; Each prefix. (setq end (match-end 0) prefix (buffer-substring begin end)) diff --git a/lisp/imap.el b/lisp/imap.el index dcd3c4b..8a87f22 100644 --- a/lisp/imap.el +++ b/lisp/imap.el @@ -166,6 +166,7 @@ (defgroup imap nil "Low-level IMAP issues." + :version "21.1" :group 'mail) (defcustom imap-kerberos4-program '("imtest -m kerberos_v4 -u %l -p %p %s" @@ -520,7 +521,8 @@ If ARGS, PROMPT is used as an argument to `format'." response) (when process (with-current-buffer buffer - (setq imap-client-eol "\n") + (setq imap-client-eol "\n" + imap-calculate-literal-size-first t) (while (and (memq (process-status process) '(open run)) (goto-char (point-min)) ;; cyrus 1.6.x (13? < x <= 22) queries capabilities @@ -1460,8 +1462,11 @@ first element, rest of list contain the saved articles' UIDs." (if (imap-ok-p (imap-send-command-wait cmd)) t (when (and (not dont-create) - (imap-mailbox-get-1 'trycreate mailbox)) - (imap-mailbox-create-1 mailbox) + ;; removed because of buggy Oracle server + ;; that doesn't send TRYCREATE tags (which + ;; is a MUST according to specifications): + ;;(imap-mailbox-get-1 'trycreate mailbox) + (imap-mailbox-create-1 mailbox)) (imap-ok-p (imap-send-command-wait cmd))))) (or no-copyuid (imap-message-copyuid-1 mailbox))))))) diff --git a/lisp/mail-source.el b/lisp/mail-source.el index 0f3f7a7..5c54fb6 100644 --- a/lisp/mail-source.el +++ b/lisp/mail-source.el @@ -1,5 +1,5 @@ ;;; mail-source.el --- functions for fetching mail -;; Copyright (C) 1999, 2000 Free Software Foundation, Inc. +;; Copyright (C) 1999, 2000, 2001 Free Software Foundation, Inc. ;; Author: Lars Magne Ingebrigtsen ;; Keywords: news, mail @@ -39,6 +39,7 @@ (defgroup mail-source nil "The mail-fetching library." + :version "21.1" :group 'gnus) ;; Define these at compile time to avoid dragging in imap always. @@ -92,12 +93,12 @@ See Info node `(gnus)Mail Source Specifiers'." (const :format "" pop) (checklist :tag "Options" :greedy t (group :inline t - (const :format "" :value :server) + (const :format "" :value :server) (string :tag "Server")) (group :inline t - (const :format "" :value :port) + (const :format "" :value :port) (choice :tag "Port" - :value "pop3" + :value "pop3" (number :format "%v") (string :format "%v"))) (group :inline t @@ -119,7 +120,7 @@ See Info node `(gnus)Mail Source Specifiers'." (const :format "" :value :function) (function :tag "Function")) (group :inline t - (const :format "" + (const :format "" :value :authentication) (choice :tag "Authentication" :value apop @@ -145,8 +146,8 @@ See Info node `(gnus)Mail Source Specifiers'." (string :tag "Server")) (group :inline t (const :format "" :value :port) - (choice :tag "Port" - :value 143 + (choice :tag "Port" + :value 143 number string)) (group :inline t (const :format "" :value :user) @@ -160,6 +161,9 @@ See Info node `(gnus)Mail Source Specifiers'." :value network ,@mail-source-imap-streams)) (group :inline t + (const :format "" :value :program) + (string :tag "Program")) + (group :inline t (const :format "" :value :authenticator) (choice :tag "Authenticator" @@ -171,7 +175,7 @@ See Info node `(gnus)Mail Source Specifiers'." :value "INBOX")) (group :inline t (const :format "" :value :predicate) - (string :tag "Predicate" + (string :tag "Predicate" :value "UNSEEN UNDELETED")) (group :inline t (const :format "" :value :fetchflag) @@ -187,7 +191,7 @@ See Info node `(gnus)Mail Source Specifiers'." (cons :tag "Webmail server" (const :format "" webmail) (checklist :tag "Options" :greedy t - (group :inline t + (group :inline t (const :format "" :value :subtype) ;; Should be generated from ;; `webmail-type-definition', but we @@ -234,7 +238,7 @@ If non-nil, this maildrop will be checked periodically for new mail." :group 'mail-source :type 'integer) -(defcustom mail-source-delete-incoming t +(defcustom mail-source-delete-incoming nil "*If non-nil, delete incoming files after handling." :group 'mail-source :type 'boolean) @@ -298,6 +302,7 @@ Common keywords should be listed here.") (:server (getenv "MAILHOST")) (:port) (:stream) + (:program) (:authentication) (:user (or (user-login-name) (getenv "LOGNAME") (getenv "USER"))) (:password) @@ -744,7 +749,7 @@ If ARGS, PROMPT is used as an argument to `format'." (defvar mail-source-report-new-mail-timer nil) (defvar mail-source-report-new-mail-idle-timer nil) -(eval-when-compile +(eval-when-compile (if (featurep 'xemacs) (require 'itimer) (require 'timer))) @@ -817,16 +822,16 @@ This only works when `display-time' is enabled." (when (and (not (file-directory-p file)) (not (if function (funcall function file mail-source-crash-box) - (let ((coding-system-for-write + (let ((coding-system-for-write mm-text-coding-system) - (coding-system-for-read + (coding-system-for-read mm-text-coding-system)) (with-temp-file mail-source-crash-box (insert-file-contents file) (goto-char (point-min)) ;;; ;; Unix mail format ;;; (unless (looking-at "\n*From ") -;;; (insert "From maildir " +;;; (insert "From maildir " ;;; (current-time-string) "\n")) ;;; (while (re-search-forward "^From " nil t) ;;; (replace-match ">From ")) @@ -863,6 +868,7 @@ This only works when `display-time' is enabled." (found 0) (buf (get-buffer-create (generate-new-buffer-name " *imap source*"))) (mail-source-string (format "imap:%s:%s" server mailbox)) + (imap-shell-program (or (list program) imap-shell-program)) remove) (if (and (imap-open server port stream authentication buf) (imap-authenticate @@ -922,14 +928,14 @@ This only works when `display-time' is enabled." (when (eq authentication 'password) (setq password (or password - (cdr (assoc (format "webmail:%s:%s" subtype user) + (cdr (assoc (format "webmail:%s:%s" subtype user) mail-source-password-cache)) (mail-source-read-passwd (format "Password for %s at %s: " user subtype)))) (when (and password - (not (assoc (format "webmail:%s:%s" subtype user) + (not (assoc (format "webmail:%s:%s" subtype user) mail-source-password-cache))) - (push (cons (format "webmail:%s:%s" subtype user) password) + (push (cons (format "webmail:%s:%s" subtype user) password) mail-source-password-cache))) (webmail-fetch mail-source-crash-box subtype user password) (mail-source-callback callback (symbol-name subtype))))) diff --git a/lisp/nnimap.el b/lisp/nnimap.el index 917f994..dddb85d 100644 --- a/lisp/nnimap.el +++ b/lisp/nnimap.el @@ -537,7 +537,7 @@ If EXAMINE is non-nil the group is selected read-only." (> nnimap-length nnmail-large-newsgroup) (nnheader-message 6 "nnimap: Retrieving headers...done"))))) -(defun nnimap-use-nov-p (group server) +(defun nnimap-dont-use-nov-p (group server) (or gnus-nov-is-evil nnimap-nov-is-evil (unless (and (gnus-make-directory (file-name-directory @@ -551,7 +551,7 @@ If EXAMINE is non-nil the group is selected read-only." (when (nnimap-possibly-change-group group server) (with-current-buffer nntp-server-buffer (erase-buffer) - (if (nnimap-use-nov-p group server) + (if (nnimap-dont-use-nov-p group server) (nnimap-retrieve-headers-from-server (gnus-compress-sequence articles) group server) (let (uids cached low high) @@ -1100,22 +1100,37 @@ function is generally only called when Gnus is shutting down." (gnus-message 5 "nnimap: Marking article %d for deletion..." imap-current-message)) + +(defun nnimap-expiry-target (arts group server) + (unless (eq nnmail-expiry-target 'delete) + (with-current-buffer nntp-server-buffer + (dolist (art (gnus-uncompress-sequence arts)) + (nnimap-request-article art group server) + ;; hints for optimization in `nnimap-request-accept-article' + (let ((nnimap-current-move-article art) + (nnimap-current-move-group group) + (nnimap-current-move-server server)) + (nnmail-expiry-target-group nnmail-expiry-target group)))))) + ;; Notice that we don't actually delete anything, we just mark them deleted. (deffoo nnimap-request-expire-articles (articles group &optional server force) (let ((artseq (gnus-compress-sequence articles))) (when (and artseq (nnimap-possibly-change-group group server)) (with-current-buffer nnimap-server-buffer (if force - (and (imap-message-flags-add - (imap-range-to-message-set artseq) "\\Deleted") - (setq articles nil)) + (progn + (nnimap-expiry-target artseq group server) + (when (imap-message-flags-add (imap-range-to-message-set artseq) + "\\Deleted") + (setq articles nil))) (let ((days (or (and nnmail-expiry-wait-function (funcall nnmail-expiry-wait-function group)) nnmail-expiry-wait))) (cond ((eq days 'immediate) - (and (imap-message-flags-add - (imap-range-to-message-set artseq) "\\Deleted") - (setq articles nil))) + (nnimap-expiry-target artseq group server) + (when (imap-message-flags-add + (imap-range-to-message-set artseq) "\\Deleted") + (setq articles nil))) ((numberp days) (let ((oldarts (imap-search (format "UID %s NOT SINCE %s" @@ -1123,6 +1138,7 @@ function is generally only called when Gnus is shutting down." (nnimap-date-days-ago days)))) (imap-fetch-data-hook '(nnimap-request-expire-articles-progress))) + (nnimap-expiry-target oldarts group server) (and oldarts (imap-message-flags-add (imap-range-to-message-set diff --git a/lisp/nnslashdot.el b/lisp/nnslashdot.el index 3762927..6286c86 100644 --- a/lisp/nnslashdot.el +++ b/lisp/nnslashdot.el @@ -1,5 +1,5 @@ ;;; nnslashdot.el --- interfacing with Slashdot -;; Copyright (C) 1999, 2000 Free Software Foundation, Inc. +;; Copyright (C) 1999, 2000, 2001 Free Software Foundation, Inc. ;; Author: Lars Magne Ingebrigtsen ;; Keywords: news @@ -57,6 +57,9 @@ "http://slashdot.org/article.pl?sid=%s&mode=nocomment" "Where nnslashdot will fetch the article from.") +(defvoo nnslashdot-backslash-url "http://slashdot.org/slashdot.xml" + "Where nnslashdot will fetch the stories from.") + (defvoo nnslashdot-threshold -1 "The article threshold.") @@ -155,7 +158,7 @@ "by ]+>\\([^<]+\\)[ \t\n]*.*(\\([^)]+\\))") (progn (goto-char (- (match-end 0) 5)) - (setq from (concat + (setq from (concat (nnweb-decode-entities-string (match-string 1)) " <" (match-string 2) ">"))) (setq from "") @@ -183,7 +186,7 @@ (concat subject " (" score ")") from date (concat "<" (nnslashdot-sid-strip sid) "%" - (number-to-string (1+ article)) + (number-to-string (1+ article)) "@slashdot>") (if parent (concat "<" (nnslashdot-sid-strip sid) "%" @@ -257,7 +260,7 @@ "by ]+>\\([^<]+\\)[ \t\n]*.*(\\([^)]+\\))") (progn (goto-char (- (match-end 0) 5)) - (setq from (concat + (setq from (concat (nnweb-decode-entities-string (match-string 1)) " <" (match-string 2) ">"))) (setq from "") @@ -284,7 +287,7 @@ (1+ article) (concat subject " (" score ")") from date (concat "<" (nnslashdot-sid-strip sid) "%" - (number-to-string (1+ article)) + (number-to-string (1+ article)) "@slashdot>") (if parent (concat "<" (nnslashdot-sid-strip sid) "%" @@ -385,9 +388,9 @@ sid elem description articles gname) (condition-case why ;; First we do the Ultramode to get info on all the latest groups. - (progn + (progn (mm-with-unibyte-buffer - (nnweb-insert "http://slashdot.org/slashdot.xml" t) + (nnweb-insert nnslashdot-backslash-url t) (goto-char (point-min)) (while (search-forward "" nil t) (narrow-to-region (point) (search-forward "")) @@ -397,8 +400,8 @@ (nnweb-decode-entities-string (match-string 1))) (re-search-forward "\\([^<]+\\)") (setq sid (match-string 1)) - (string-match "/\\([0-9/]+\\)\\(.shtml\\|$\\)" sid) - (setq sid (concat "00/" (match-string 1 sid))) + (string-match "sid=\\([0-9/]+\\)\\(.shtml\\|$\\)" sid) + (setq sid (match-string 1 sid)) (re-search-forward "\\([^<]+\\)") (setq articles (string-to-number (match-string 1))) (setq gname (concat description " (" sid ")")) @@ -431,7 +434,7 @@ (nnslashdot-write-groups) (nnslashdot-generate-active) t)) - + (deffoo nnslashdot-request-newgroups (date &optional server) (nnslashdot-possibly-change-server nil server) (nnslashdot-generate-active) @@ -519,7 +522,7 @@ (defun nnslashdot-write-groups () (with-temp-file (expand-file-name "groups" nnslashdot-directory) (prin1 nnslashdot-groups (current-buffer)))) - + (defun nnslashdot-init (server) "Initialize buffers and such." (unless (file-exists-p nnslashdot-directory) diff --git a/lisp/nnultimate.el b/lisp/nnultimate.el index baaf17c..0567ecc 100644 --- a/lisp/nnultimate.el +++ b/lisp/nnultimate.el @@ -80,7 +80,7 @@ "postings.*editpost\\|forumdisplay\\|getbio") headers article subject score from date lines parent point contents tinfo fetchers map elem a href garticles topic old-max - inc datel table string current-page total-contents pages + inc datel table current-page total-contents pages farticles forum-contents parse furl-fetched mmap farticle) (setq map mapping) (while (and (setq article (car articles)) @@ -132,11 +132,9 @@ (setq contents (ignore-errors (w3-parse-buffer (current-buffer)))) (setq table (nnultimate-find-forum-table contents)) - (setq string (mapconcat 'identity (nnweb-text table) "")) - (when (string-match "topic is \\([0-9]\\) pages" string) - (setq pages (string-to-number (match-string 1 string))) - (setcdr table nil) - (setq table (nnultimate-find-forum-table contents))) + (goto-char (point-min)) + (when (re-search-forward "topic is \\([0-9]+\\) pages" nil t) + (setq pages (string-to-number (match-string 1)))) (setq contents (cdr (nth 2 (car (nth 2 table))))) (setq total-contents (nconc total-contents contents)) (incf current-page)) @@ -165,13 +163,21 @@ (setq date (substring (car datel) (match-end 0)) datel nil)) (pop datel)) - (setq date (delete "" (split-string date "[- \n\t\r    ]"))) + (setq date (delete "" (split-string + date "[-, \n\t\r    ]"))) (if (or (member "AM" date) (member "PM" date)) - (setq date (format "%s %s %s %s" - (car (rassq (string-to-number (nth 0 date)) - parse-time-months)) - (nth 1 date) (nth 2 date) (nth 3 date))) + (setq date (format + "%s %s %s %s" + (nth 1 date) + (if (and (>= (length (nth 0 date)) 3) + (assoc (downcase + (substring (nth 0 date) 0 3)) + parse-time-months)) + (substring (nth 0 date) 0 3) + (car (rassq (string-to-number (nth 0 date)) + parse-time-months))) + (nth 2 date) (nth 3 date))) (setq date (format "%s %s %s %s" (car (rassq (string-to-number (nth 1 date)) parse-time-months)) diff --git a/lisp/nnwarchive.el b/lisp/nnwarchive.el index 5103b55..1a34dde 100644 --- a/lisp/nnwarchive.el +++ b/lisp/nnwarchive.el @@ -696,14 +696,17 @@ (progn (forward-line) (point))) ;; I hate to download the url encode it, then immediately ;; decode it. - ;; FixMe: Find a better solution to attach the URL. - ;; Maybe do some hack in external part of mml-generate-mim-1. - (insert "<#part>" - "\n--\nExternal: \n" - (format "" + (insert "<#external" + " type=" + (or (and url + (string-match "\\.[^\\.]+$" url) + (mailcap-extension-to-mime + (match-string 0 url))) + "application/octet-stream") + (format " url=\"http://www.mail-archive.com/%s/%s\"" group url) - "\n--\n" - "<#/part>") + ">\n" + "<#/external>") (setq mime t)) (t (setq p (point)) diff --git a/lisp/webmail.el b/lisp/webmail.el index d947ca0..27fc0eb 100644 --- a/lisp/webmail.el +++ b/lisp/webmail.el @@ -1,5 +1,5 @@ -;;; webmail.el --- interfacing with web mail -;; Copyright (C) 1999, 2000 Free Software Foundation, Inc. +;;; webmail.el --- interface of web mail +;; Copyright (C) 1999, 2000, 2001 Free Software Foundation, Inc. ;; Author: Shenghuo Zhu ;; Keywords: hotmail netaddress my-deja netscape @@ -32,7 +32,7 @@ ;; Todo: To support more web mail servers. -;; Known bugs: +;; Known bugs: ;; 1. Net@ddress may corrupt `X-Face'. ;; Warning: @@ -81,8 +81,8 @@ ;;(list-url "%s" webmail-aux) (list-snarf . webmail-hotmail-list) (article-snarf . webmail-hotmail-article) - (trash-url - "%s&login=%s&f=33792&curmbox=ACTIVE&_lang=&foo=inbox&js=&page=&%s=on&_HMaction=MoveTo&tobox=trAsH&nullbox=" + (trash-url + "%s&login=%s&f=33792&curmbox=ACTIVE&_lang=&foo=inbox&js=&page=&%s=on&_HMaction=MoveTo&tobox=trAsH&nullbox=" webmail-aux user id)) (yahoo (paranoid agent cookie post) @@ -90,7 +90,7 @@ (open-url "http://mail.yahoo.com/") (open-snarf . webmail-yahoo-open) (login-url;; yahoo will not accept GET - content + content ("%s" webmail-aux) ".tries=&.src=ym&.last=&promo=&.intl=&.bypass=&.partner=&.chkP=Y&.done=&login=%s&passwd=%s" user password) @@ -98,7 +98,7 @@ (list-url "%s&rb=Inbox&YN=1" webmail-aux) (list-snarf . webmail-yahoo-list) (article-snarf . webmail-yahoo-article) - (trash-url + (trash-url "%s/ym/ShowFolder?YY=52107&inc=50&order=down&sort=date&pos=0&box=Inbox&DEL=Delete&destBox=&Mid=%s&destBox2=" webmail-aux id)) (netaddress @@ -107,18 +107,18 @@ (open-url "http://www.netaddress.com/") (open-snarf . webmail-netaddress-open) (login-url - content + content ("%s" webmail-aux) - "LoginState=2&SuccessfulLogin=%%2Ftpl&NewServerName=www.netaddress.com&JavaScript=JavaScript1.2&DomainID=4&NA31site=classic.netaddress.com&NA31port=80&UserID=%s&passwd=%s" + "LoginState=2&SuccessfulLogin=%%2Ftpl&NewServerName=www.netaddress.com&JavaScript=JavaScript1.2&DomainID=4&Domain=usa.net&NA31site=classic.netaddress.com&NA31port=80&UserID=%s&passwd=%s" user password) (login-snarf . webmail-netaddress-login) - (list-url + (list-url "http://www.netaddress.com/tpl/Mail/%s/List?FolderID=-4&SortUseCase=True" webmail-session) (list-snarf . webmail-netaddress-list) (article-url "http://www.netaddress.com/") (article-snarf . webmail-netaddress-article) - (trash-url + (trash-url "http://www.netaddress.com/tpl/Message/%s/Move?FolderID=-4&Q=%s&N=&Sort=Date&F=-1" webmail-session id)) (netscape @@ -127,37 +127,35 @@ (open-url "http://ureg.netscape.com/iiop/UReg2/login/login?U2_LA=en&U2_BACK_FROM_CJ=true&U2_CS=iso-8859-1&U2_ENDURL=http://webmail.netscape.com/tpl/Subscribe/Step1&U2_NEW_ENDURL=http://webmail.netscape.com/tpl/Subscribe/Step1&U2_EXITURL=http://home.netscape.com/&U2_SOURCE=Webmail") (open-snarf . webmail-netscape-open) (login-url - content + content ("http://ureg.netscape.com/iiop/UReg2/login/loginform") "U2_USERNAME=%s&U2_PASSWORD=%s%s" user password webmail-aux) (login-snarf . webmail-netaddress-login) - (list-url + (list-url "http://webmail.netscape.com/tpl/Mail/%s/List?FolderID=-4&SortUseCase=True" webmail-session) (list-snarf . webmail-netaddress-list) (article-url "http://webmail.netscape.com/") (article-snarf . webmail-netscape-article) - (trash-url + (trash-url "http://webmail.netscape.com/tpl/Message/%s/Move?FolderID=-4&Q=%s&N=&Sort=Date&F=-1" webmail-session id)) (my-deja (paranoid cookie post) (address . "www.my-deja.com") - (open-url "http://www.deja.com/my/pr.xp") - (open-snarf . webmail-my-deja-open) + ;;(open-snarf . webmail-my-deja-open) (login-url - content - ("%s" webmail-aux) - "member_name=%s&pw=%s&go=&priv_opt_MyDeja99=" + content + ("http://mydeja.google.com/cgi-bin/deja/maillogin.py") + "userid=%s&password=%s" user password) - (list-url "http://www.deja.com/rg_gotomail.xp") (list-snarf . webmail-my-deja-list) (article-snarf . webmail-my-deja-article) (trash-url webmail-aux id)))) (defvar webmail-variables - '(address article-snarf article-url list-snarf list-url + '(address article-snarf article-url list-snarf list-url login-url login-snarf open-url open-snarf site articles post-process paranoid trash-url)) @@ -201,7 +199,7 @@ (defun webmail-debug (str) (with-temp-buffer (insert "\n---------------- A bug at " str " ------------------\n") - (mapcar #'(lambda (sym) + (mapcar #'(lambda (sym) (if (boundp sym) (pp `(setq ,sym ',(eval sym)) (current-buffer)))) '(webmail-type user)) @@ -264,7 +262,7 @@ (defun webmail-url (xurl) (mm-with-unibyte-current-buffer - (cond + (cond ((eq (car xurl) 'content) (pop xurl) (webmail-fetch-simple (if (stringp (car xurl)) @@ -300,7 +298,7 @@ ;; instead of 303, though they mean 303. (defun webmail-url-confirmation-func (prompt) - (cond + (cond ((equal prompt (concat "Honor redirection with non-GET method " "(possible security risks)? ")) nil) @@ -311,7 +309,7 @@ (defun webmail-refresh-redirect () "Redirect refresh url in META." (goto-char (point-min)) - (while (re-search-forward + (while (re-search-forward "]*URL=\\([^\"]+\\)\"" nil t) (let ((url (match-string 1))) @@ -341,19 +339,19 @@ item id (n 0)) (webmail-init) (setq webmail-articles nil) - (when webmail-open-url + (when webmail-open-url (erase-buffer) (webmail-url webmail-open-url)) (if webmail-open-snarf (funcall webmail-open-snarf)) - (when webmail-login-url + (when webmail-login-url (erase-buffer) (webmail-url webmail-login-url)) - (if webmail-login-snarf + (if webmail-login-snarf (funcall webmail-login-snarf)) - (when webmail-list-url + (when webmail-list-url (erase-buffer) (webmail-url webmail-list-url)) - (if webmail-list-snarf + (if webmail-list-snarf (funcall webmail-list-snarf)) (while (setq item (pop webmail-articles)) (message "Fetching mail #%d..." (setq n (1+ n))) @@ -361,7 +359,7 @@ (mm-with-unibyte-current-buffer (nnweb-insert (cdr item))) (setq id (car item)) - (if webmail-article-snarf + (if webmail-article-snarf (funcall webmail-article-snarf file id)) (when (and webmail-trash-url webmail-move-to-trash-can) (message "Move mail #%d to trash can..." n) @@ -371,7 +369,7 @@ (let (buf) (while (setq buf (pop webmail-buffer-list)) (kill-buffer buf)))) - (error + (error (let (buf) (while (setq buf (pop webmail-buffer-list)) (kill-buffer buf))) @@ -391,7 +389,7 @@ (defun webmail-hotmail-open () (goto-char (point-min)) - (if (re-search-forward + (if (re-search-forward "action=\"https?://\\([^/]+\\)/cgi-bin/dologin" nil t) (setq webmail-aux (match-string 1)) (webmail-error "open@1"))) @@ -399,12 +397,12 @@ (defun webmail-hotmail-login () (let (site) (goto-char (point-min)) - (if (re-search-forward + (if (re-search-forward "https?://\\([^/]+hotmail\\.msn\\.com\\)/cgi-bin/" nil t) (setq site (match-string 1)) (webmail-error "login@1")) (goto-char (point-min)) - (if (re-search-forward + (if (re-search-forward "\\(/cgi-bin/HoTMaiL\\?[^\"]*a=b[^\"]*\\)" nil t) (setq webmail-aux (concat "http://" site (match-string 1))) (webmail-error "login@2")))) @@ -415,27 +413,27 @@ (let (site url newp (total "0")) (if (eobp) (setq total "0") - (if (re-search-forward "\\([0-9]+\\) *(\\([0-9]+\\) new)" nil t) - (message "Found %s (%s new)" (setq total (match-string 1)) + (if (re-search-forward "\\([0-9]+\\) *(\\([0-9]+\\) new)" nil t) + (message "Found %s (%s new)" (setq total (match-string 1)) (match-string 2)) - (if (re-search-forward "\\([0-9]+\\) new" nil t) + (if (re-search-forward "\\([0-9]+\\) new" nil t) (message "Found %s new" (setq total (match-string 1))) (webmail-error "list@0")))) (unless (equal total "0") (goto-char (point-min)) - (if (re-search-forward + (if (re-search-forward "https?://\\([^/]+hotmail\\.msn\\.com\\)/cgi-bin/" nil t) (setq site (match-string 1)) (webmail-error "list@1")) (goto-char (point-min)) (if (re-search-forward "disk=\\([^&]*\\)&" nil t) - (setq webmail-aux - (concat "http://" site "/cgi-bin/HoTMaiL?disk=" + (setq webmail-aux + (concat "http://" site "/cgi-bin/HoTMaiL?disk=" (match-string 1))) (webmail-error "list@2")) (goto-char (point-max)) - (while (re-search-backward - "newmail\\.gif\\|href=\"\\(/cgi-bin/getmsg\\?[^\"]+\\)\"" + (while (re-search-backward + "newmail\\.gif\\|href=\"\\(/cgi-bin/getmsg\\?[^\"]+\\)\"" nil t) (if (setq url (match-string 1)) (progn @@ -443,7 +441,7 @@ (let (id) (if (string-match "msg=\\([^&]+\\)" url) (setq id (match-string 1 url))) - (push (cons id (concat "http://" site url "&raw=0")) + (push (cons id (concat "http://" site url "&raw=0")) webmail-articles))) (setq newp nil)) (setq newp t)))))) @@ -453,7 +451,7 @@ (defun webmail-hotmail-article (file id) (goto-char (point-min)) (skip-chars-forward " \t\n\r") - (unless (eobp) + (unless (eobp) (if (not (search-forward "
" nil t))
 	(webmail-error "article@3"))
     (skip-chars-forward "\n\r\t ")
@@ -489,7 +487,7 @@
       (narrow-to-region (point-min) (point))
       (if (not (search-backward "" nil t)
@@ -507,8 +505,8 @@
       (widen)
       (insert "\n")
       (setq p (point))
-      (while (re-search-forward 
-	      "\\|
\\|\\(http://[^/]+/cgi-bin/getmsg/\\([^\?]+\\)\?[^\"]*\\)\"" + (while (re-search-forward + "\\|
\\|\\(http://[^/]+/cgi-bin/getmsg/\\([^\?]+\\)\?[^\"]*\\)\"" nil t) (if (setq attachment (match-string 1)) (let ((filename (match-string 2)) @@ -520,7 +518,7 @@ (push (current-buffer) webmail-buffer-list) (setq bufname (buffer-name))) (setq mime t) - (insert "<#part type=" + (insert "<#part type=" (or (and filename (string-match "\\.[^\\.]+$" filename) (mailcap-extension-to-mime @@ -537,7 +535,7 @@ (webmail-error "article@1.2") (delete-region (match-beginning 0) (match-end 0))) (setq count 1) - (while (and (> count 0) + (while (and (> count 0) (re-search-forward "
\\|\\(
\\)" nil t)) (if (match-string 1) (setq count (1+ count)) @@ -546,7 +544,7 @@ (match-end 0)))))) (narrow-to-region p (point)) (goto-char (point-min)) - (cond + (cond ((looking-at "
")
 	    (goto-char (match-end 0))
 	    (if (looking-at "$") (forward-char))
@@ -571,7 +569,7 @@
 	      "@" (symbol-name webmail-type) "\n")
       (if id
 	  (insert (format "X-Message-ID: <%s@hotmail.com>\n" id)))
-      (unless (looking-at "$") 
+      (unless (looking-at "$")
 	(if (search-forward "\n\n" nil t)
 	    (forward-line -1)
 	  (webmail-error "article@2")))
@@ -610,21 +608,21 @@
 (defun webmail-yahoo-list ()
   (let (url (newp t) (tofetch 0))
     (goto-char (point-min))
-    (when (re-search-forward 
-	   "showing [0-9]+-\\([0-9]+\\) of \\([0-9]+\\)" nil t) 
+    (when (re-search-forward
+	   "showing [0-9]+-\\([0-9]+\\) of \\([0-9]+\\)" nil t)
       ;;(setq listed (match-string 1))
       (message "Found %s mail(s)" (match-string 2)))
     (if (string-match "http://[^/]+" webmail-aux)
 	(setq webmail-aux (match-string 0 webmail-aux))
       (webmail-error "list@1"))
     (goto-char (point-min))
-    (while (re-search-forward 
+    (while (re-search-forward
 	    "bgcolor=\"#eeeeee\"\\|href=\"\\(/ym/ShowLetter\\?MsgId=\\([^&]+\\)&[^\"]*\\)\""
 	    nil t)
       (if (setq url (match-string 1))
 	  (progn
 	    (when (or newp (not webmail-newmail-only))
-	      (push (cons (match-string 2) (concat webmail-aux url "&toc=1")) 
+	      (push (cons (match-string 2) (concat webmail-aux url "&toc=1"))
 		    webmail-articles)
 	      (setq tofetch (1+ tofetch)))
 	    (setq newp t))
@@ -640,7 +638,7 @@
 	  (webmail-error "article@1"))
       (if (not (search-forward "" nil t))
 	  (webmail-error "article@3"))
       (narrow-to-region (point-min) (match-end 0))
@@ -702,7 +700,7 @@
 	      "@" (symbol-name webmail-type) "\n")
       (if id
 	  (insert (format "X-Message-ID: <%s@yahoo.com>\n" id)))
-      (unless (looking-at "$") 
+      (unless (looking-at "$")
 	(if (search-forward "\n\n" nil t)
 	    (forward-line -1)
 	  (webmail-error "article@2")))
@@ -724,8 +722,8 @@
 (defun webmail-netscape-open ()
   (goto-char (point-min))
   (setq webmail-aux "")
-  (while (re-search-forward 
-	  "TYPE=hidden *NAME=\\([^ ]+\\) *VALUE=\"\\([^\"]+\\)" 
+  (while (re-search-forward
+	  "TYPE=hidden *NAME=\\([^ ]+\\) *VALUE=\"\\([^\"]+\\)"
 	  nil t)
     (setq webmail-aux (concat webmail-aux "&" (match-string 1) "="
 			      (match-string 2)))))
@@ -747,16 +745,16 @@
   (webmail-refresh-redirect)
   (let (item id)
     (goto-char (point-min))
-    (when (re-search-forward 
-	   "(\\([0-9]+\\) unread, \\([0-9]+\\) total)" nil t) 
-      (message "Found %s mail(s), %s unread" 
+    (when (re-search-forward
+	   "(\\([0-9]+\\) unread, \\([0-9]+\\) total)" nil t)
+      (message "Found %s mail(s), %s unread"
 	       (match-string 2) (match-string 1)))
     (goto-char (point-min))
-    (while (re-search-forward 
+    (while (re-search-forward
 	    "MR\\[i\\]\\.R='\\([^']*\\)'\\|MR\\[i\\]\\.Q='\\([^']+\\)'" nil t)
       (if (setq id (match-string 2))
-	  (setq item 
-		(cons id 
+	  (setq item
+		(cons id
 		      (format "%s/tpl/Message/%s/Read?Q=%s&FolderID=-4&SortUseCase=True&Sort=Date&Headers=True"
 			      (car webmail-article-url)
 			      webmail-session id)))
@@ -767,7 +765,7 @@
 
 (defun webmail-netaddress-single-part ()
   (goto-char (point-min))
-  (cond 
+  (cond
    ((looking-at "[\t\040\r\n]*]+>[\t\040\r\n]*")
     ;; text/plain
     (replace-match "")
@@ -796,7 +794,7 @@
 	  (webmail-error "article@1"))
       (if (not (search-forward "
" nil t)) (webmail-error "article@2")) - (delete-region (point-min) (match-beginning 0)) + (delete-region (point-min) (match-beginning 0)) (if (not (search-forward "
" nil t)) (webmail-error "article@3")) (narrow-to-region (point-min) (match-end 0)) @@ -826,7 +824,7 @@ (forward-line 14) (delete-region p (point)) (goto-char (point-max)) - (unless (re-search-backward + (unless (re-search-backward "[\040\t]*
[\040\t\r\n]*
[\040\t\r\n]*<#/part>\n") (setq p (point)))) (delete-region p p1) - (narrow-to-region + (narrow-to-region p - (if (search-forward + (if (search-forward "" nil t) (match-beginning 0) @@ -881,7 +879,7 @@ "@" (symbol-name webmail-type) "\n") (if id (insert (format "X-Message-ID: <%s@%s>\n" id webmail-address))) - (unless (looking-at "$") + (unless (looking-at "$") (if (search-forward "\n\n" nil t) (forward-line -1) (webmail-error "article@2"))) @@ -890,7 +888,7 @@ (goto-char (point-min)) (while (not (eobp)) (if (looking-at "MIME-Version\\|Content-Type") - (delete-region (point) + (delete-region (point) (progn (forward-line 1) (if (re-search-forward "^[^ \t]" nil t) @@ -921,7 +919,7 @@ (webmail-error "article@1")) (if (not (search-forward "" nil t)) (webmail-error "article@2")) - (delete-region (point-min) (match-beginning 0)) + (delete-region (point-min) (match-beginning 0)) (if (not (search-forward "" nil t)) (webmail-error "article@3")) (narrow-to-region (point-min) (match-end 0)) @@ -954,7 +952,7 @@ (forward-line 14) (delete-region p (point)) (goto-char (point-max)) - (unless (re-search-backward + (unless (re-search-backward "<#/part>\n") (setq p (point)))) (delete-region p p1) - (narrow-to-region + (narrow-to-region p - (if (search-forward + (if (search-forward "
" nil t) (match-beginning 0) @@ -1009,7 +1007,7 @@ "@" (symbol-name webmail-type) "\n") (if id (insert (format "X-Message-ID: <%s@%s>\n" id webmail-address))) - (unless (looking-at "$") + (unless (looking-at "$") (if (search-forward "\n\n" nil t) (forward-line -1) (webmail-error "article@2"))) @@ -1018,7 +1016,7 @@ (goto-char (point-min)) (while (not (eobp)) (if (looking-at "MIME-Version\\|Content-Type") - (delete-region (point) + (delete-region (point) (progn (forward-line 1) (if (re-search-forward "^[^ \t]" nil t) @@ -1045,7 +1043,7 @@ (defun webmail-my-deja-open () (webmail-refresh-redirect) (goto-char (point-min)) - (if (re-search-forward "action=\"\\([^\"]+login_confirm\\.xp[^\"]*\\)\"" + (if (re-search-forward "action=\"\\([^\"]+maillogin\\.py[^\"]*\\)\"" nil t) (setq webmail-aux (match-string 1)) (webmail-error "open@1"))) @@ -1053,26 +1051,26 @@ (defun webmail-my-deja-list () (let (item id newp base) (goto-char (point-min)) - (when (re-search-forward "href=\"\\(\\([^\"]*\\)/mailnf\\.[^\"]*\\)\"" + (when (re-search-forward "href=\"\\(\\([^\"]*\\)/mailnf\\.[^\"]*\\)\"" nil t) (let ((url (match-string 1))) (setq base (match-string 2)) (erase-buffer) (nnweb-insert url))) (goto-char (point-min)) - (when (re-search-forward + (when (re-search-forward "(\\([0-9]+\\) Message.?-[^>]*\\([0-9]+\\) New" - nil t) - (message "Found %s mail(s), %s unread" + nil t) + (message "Found %s mail(s), %s unread" (match-string 1) (match-string 2))) (goto-char (point-min)) - (while (re-search-forward + (while (re-search-forward "newmail\\.gif\\|href=\"[^\"]*\\(mailnf\\.[^\"]+act=view[^\"]+mid=\\([^\"&]+\\)[^\"]+\\)\"" nil t) (if (setq id (match-string 2)) (when (and (or newp (not webmail-newmail-only)) (not (assoc id webmail-articles))) - (push (cons id (setq webmail-aux + (push (cons id (setq webmail-aux (concat base "/" (match-string 1)))) webmail-articles) (setq newp nil)) @@ -1081,7 +1079,7 @@ (defun webmail-my-deja-article-part (base) (let (p) - (cond + (cond ((looking-at "[\t\040\r\n]*