From: kaoru Date: Thu, 26 Oct 2000 12:48:20 +0000 (+0000) Subject: Checkdoc. X-Git-Tag: wl-2_4-root~73 X-Git-Url: http://git.chise.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=e64882498d21cef2b964ddc18d41421ab36bd19b;p=elisp%2Fwanderlust.git Checkdoc. --- diff --git a/elmo/elmo-archive.el b/elmo/elmo-archive.el index 510140f..96f6c02 100644 --- a/elmo/elmo-archive.el +++ b/elmo/elmo-archive.el @@ -83,26 +83,26 @@ "*Regular expression of UNIX Mail delimiter.") (defvar elmo-archive-header-regexp "^[ \t]*[-=][-=][-=][-=]" - "*Common regexp of the delimiter in listing archive.") ;; marche + "*Common regexp of the delimiter in listing archive.") ; marche (defvar elmo-archive-file-regexp-alist (append (if elmo-archive-lha-dos-compatible - '((lha . "^%s\\([0-9]+\\)$")) ; OS/2,DOS w/ "-x" + '((lha . "^%s\\([0-9]+\\)$")) ; OS/2,DOS w/ "-x" '((lha . "^.*[ \t]%s\\([0-9]+\\)$"))) '((zip . "^.*[ \t]%s\\([0-9]+\\)$") (zoo . "^.*[ \t]%s\\([0-9]+\\)$") - (tar . "^%s\\([0-9]+\\)$") ; ok - (tgz . "^%s\\([0-9]+\\)$") ; ok + (tar . "^%s\\([0-9]+\\)$") ; ok + (tgz . "^%s\\([0-9]+\\)$") ; ok (rar . "^[ \t]%s\\([0-9]+\\)$")))) (defvar elmo-archive-suffix-alist '((lha . ".lzh") ; default -; (lha . ".lzs") +;;; (lha . ".lzs") (zip . ".zip") (zoo . ".zoo") -; (arc . ".arc") -; (arj . ".arj") +;;; (arc . ".arc") +;;; (arj . ".arj") (rar . ".rar") (tar . ".tar") (tgz . ".tar.gz"))) @@ -116,7 +116,7 @@ (rm . ("lha" "d")) (ls . ("lha" "l" "-x")) (cat . ("lha" "p" "-n")) - (ext . ("lha" "x")) ; "-x" + (ext . ("lha" "x")) ; "-x" ) ;; some UN|X '((cp . ("lha" "u")) @@ -146,7 +146,7 @@ (mv . ("zoo" "aMq")) (mv-pipe . ("zoo" "aMqI")) (rm . ("zoo" "Dq")) - (ls . ("zoo" "l")) ; normal + (ls . ("zoo" "l")) ; normal (cat . ("zoo" "xpq")) (ext . ("zoo" "xq")))) @@ -165,20 +165,20 @@ '((ls . ("gtar" "-tf")) (cat . ("gtar" "--posix Oxf")) (ext . ("gtar" "-xf")) - ;;(rm . ("gtar" "--posix" "--delete" "-f")) ;; well not work +;;; (rm . ("gtar" "--posix" "--delete" "-f")) ; well not work ) - '((ls . ("gtar" "-tf")) - (cat . ("gtar" "-Oxf")) - (ext . ("gtar" "-xf")) - ;;(rm . ("gtar" "--delete" "-f")) ;; well not work - ))) + '((ls . ("gtar" "-tf")) + (cat . ("gtar" "-Oxf")) + (ext . ("gtar" "-xf")) +;;; (rm . ("gtar" "--delete" "-f")) ;; well not work + ))) ;;; GNU tar (*.tar.gz, *.tar.Z, *.tar.bz2) (defvar elmo-archive-tgz-method-alist '((ls . ("gtar" "-ztf")) (cat . ("gtar" "-Ozxf")) (create . ("gtar" "-zcf")) - ;;(rm . elmo-archive-tgz-rm-func) +;;; (rm . elmo-archive-tgz-rm-func) (cp . elmo-archive-tgz-cp-func) (mv . elmo-archive-tgz-mv-func) (ext . ("gtar" "-zxf")) @@ -186,17 +186,17 @@ (decompress . ("gzip" "-d")) (compress . ("gzip")) (append . ("gtar" "-uf")) - ;;(delete . ("gtar" "--delete" "-f")) ;; well not work +;;; (delete . ("gtar" "--delete" "-f")) ; well not work )) (defvar elmo-archive-method-list '(elmo-archive-lha-method-alist elmo-archive-zip-method-alist elmo-archive-zoo-method-alist -; elmo-archive-tar-method-alist +;;; elmo-archive-tar-method-alist elmo-archive-tgz-method-alist -; elmo-archive-arc-method-alist -; elmo-archive-arj-method-alist +;;; elmo-archive-arc-method-alist +;;; elmo-archive-arj-method-alist elmo-archive-rar-method-alist)) ;;; Internal vars. @@ -342,7 +342,7 @@ TYPE specifies the archiver's symbol." t) (defun elmo-archive-create-folder (spec) - (let* ((dir (directory-file-name ;; remove tail slash. + (let* ((dir (directory-file-name ; remove tail slash. (elmo-archive-get-archive-directory (nth 1 spec)))) (type (nth 2 spec)) (arc (elmo-archive-get-archive-name (nth 1 spec) type))) @@ -354,7 +354,7 @@ TYPE specifies the archiver's symbol." (error "Create folder failed; File \"%s\" exists" dir)) ((file-directory-p dir) (if (file-exists-p arc) - t ; return value + t ; return value (elmo-archive-create-file arc type spec))) (t (elmo-make-directory dir) @@ -392,7 +392,7 @@ TYPE specifies the archiver's symbol." (defun elmo-archive-delete-folder (spec) (let* ((arc (elmo-archive-get-archive-name (nth 1 spec) (nth 2 spec)))) (if (not (file-exists-p arc)) - (error "no such file: %s" arc) + (error "No such file: %s" arc) (delete-file arc) t))) @@ -403,11 +403,11 @@ TYPE specifies the archiver's symbol." (nth 1 new-spec) (nth 2 new-spec)))) (unless (and (eq (nth 2 old-spec) (nth 2 new-spec)) (equal (nth 3 old-spec) (nth 3 new-spec))) - (error "not same archive type and prefix")) + (error "Not same archive type and prefix")) (if (not (file-exists-p old-arc)) - (error "no such file: %s" old-arc) + (error "No such file: %s" old-arc) (if (file-exists-p new-arc) - (error "already exists: %s" new-arc) + (error "Already exists: %s" new-arc) (rename-file old-arc new-arc) t)))) @@ -472,7 +472,8 @@ TYPE specifies the archiver's symbol." (elmo-archive-call-method method args t)) (elmo-delete-cr-get-content-type)))))) -(defun elmo-archive-append-msg (spec string &optional msg no-see) ;;; verrrrrry slow!! +;; verrrrrry slow!! +(defun elmo-archive-append-msg (spec string &optional msg no-see) (let* ((type (nth 2 spec)) (prefix (nth 3 spec)) (arc (elmo-archive-get-archive-name (nth 1 spec) type)) @@ -508,7 +509,7 @@ TYPE specifies the archiver's symbol." nil)) (kill-buffer tmp-buffer))))) -;;; (localdir, maildir, localnews, archive) -> archive +;; (localdir, maildir, localnews, archive) -> archive (defun elmo-archive-copy-msgs (dst-spec msgs src-spec &optional loc-alist same-number) (let* ((dst-type (nth 2 dst-spec)) @@ -689,8 +690,8 @@ TYPE specifies the archiver's symbol." (defsubst elmo-archive-article-exists-p (arc msg type) (if (not elmo-archive-check-existance-strict) - t ; nop - (save-excursion ;; added 980915 + t ; nop + (save-excursion ; added 980915 (let* ((method (elmo-archive-get-method type 'ls)) (args (list arc msg)) (buf (get-buffer-create " *ELMO ARCHIVE query*")) @@ -770,7 +771,8 @@ TYPE specifies the archiver's symbol." (narrow-to-region (point-min) header-end) (elmo-msgdb-create-overview-from-buffer number))) -(defsubst elmo-archive-msgdb-create-entity (method archive number type &optional prefix) ;; verrrry slow!! +;; verrrry slow!! +(defsubst elmo-archive-msgdb-create-entity (method archive number type &optional prefix) (let* ((msg (elmo-concat-path prefix (int-to-string number))) (arg-list (list archive msg))) (when (elmo-archive-article-exists-p archive msg type) @@ -897,13 +899,13 @@ TYPE specifies the archiver's symbol." (setq overview (append overview (nth 0 result))) (setq number-alist (append number-alist (nth 1 result))) (setq mark-alist (append mark-alist (nth 2 result)))) -; ((looking-at delim2) ;; UNIX MAIL -; (setq result (elmo-archive-parse-unixmail msgs)) -; (setq overview (append overview (nth 0 result))) -; (setq number-alist (append number-alist (nth 1 result))) -; (setq mark-alist (append mark-alist (nth 2 result)))) +;;; ((looking-at delim2) ;; UNIX MAIL +;;; (setq result (elmo-archive-parse-unixmail msgs)) +;;; (setq overview (append overview (nth 0 result))) +;;; (setq number-alist (append number-alist (nth 1 result))) +;;; (setq mark-alist (append mark-alist (nth 2 result)))) (t ;; unknown format - (error "unknown format!"))) + (error "Unknown format!"))) (when (> num elmo-display-progress-threshold) (setq i (+ n i)) (setq percent (/ (* i 100) num)) @@ -928,8 +930,8 @@ TYPE specifies the archiver's symbol." (setq sp (1+ (point))) (setq ep (prog2 (re-search-forward delim) (1+ (- (point) (length delim))))) - (if (>= sp ep) ; no article! - () ; nop + (if (>= sp ep) ; no article! + () ; nop (save-excursion (narrow-to-region sp ep) (setq entity (elmo-archive-msgdb-create-entity-subr number)) diff --git a/elmo/elmo-cache.el b/elmo/elmo-cache.el index 8e447a0..b55f5d4 100644 --- a/elmo/elmo-cache.el +++ b/elmo/elmo-cache.el @@ -51,7 +51,7 @@ (setq message-id (elmo-cache-to-msgid (file-name-nondirectory path)))) (member message-id locked)) - nil ;; Don't delete caches with mark (or locked message). + nil;; Don't delete caches with mark (or locked message). (if (and path (file-directory-p path)) (progn @@ -81,7 +81,7 @@ (delete-directory path1)))))))) (defun elmo-cache-read (msgid &optional folder number outbuf) - "Read cache contents to outbuf" + "Read cache contents to OUTBUF." (save-excursion (let ((path (elmo-cache-exists-p msgid folder number))) (when path @@ -166,7 +166,7 @@ If KBYTES is kilo bytes (This value must be float)." (cons (car (car cfl)) (car flist))))) (setq cfl (cdr cfl))) -; (prin1 firsts) +;;; (prin1 firsts) (while firsts (if (and (not oldest-entity) (cdr (cdr (car firsts)))) @@ -243,22 +243,22 @@ If KBYTES is kilo bytes (This value must be float)." (setq dirs (cdr dirs))))) (defun elmo-cache-save (msgid partial folder number &optional inbuf) - "If partial is non-nil, save current buffer (or INBUF) as partial cache." + "If PARTIAL is non-nil, save current buffer (or INBUF) as partial cache." (condition-case nil - (save-excursion - (let* ((path (if partial - (elmo-cache-get-path msgid folder number) - (elmo-cache-get-path msgid))) - dir tmp-buf) - (when path - (setq dir (directory-file-name (file-name-directory path))) - (if (not (file-exists-p dir)) - (elmo-make-directory dir)) - (if inbuf (set-buffer inbuf)) - (goto-char (point-min)) - (as-binary-output-file (write-region (point-min) (point-max) - path nil 'no-msg))))) - (error))) + (save-excursion + (let* ((path (if partial + (elmo-cache-get-path msgid folder number) + (elmo-cache-get-path msgid))) + dir tmp-buf) + (when path + (setq dir (directory-file-name (file-name-directory path))) + (if (not (file-exists-p dir)) + (elmo-make-directory dir)) + (if inbuf (set-buffer inbuf)) + (goto-char (point-min)) + (as-binary-output-file (write-region (point-min) (point-max) + path nil 'no-msg))))) + (error))) (defun elmo-cache-exists-p (msgid &optional folder number) "Returns the path if the cache exists." @@ -311,7 +311,7 @@ If KBYTES is kilo bytes (This value must be float)." ret-val)) (defun elmo-cache-collect-sub-directories (init dir &optional recursively) - "Collect subdirectories under 'dir'" + "Collect subdirectories under DIR." (let ((dirs (delete (expand-file-name elmo-cache-dirname elmo-msgdb-dir) @@ -362,13 +362,13 @@ If KBYTES is kilo bytes (This value must be float)." ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; -;;; buffer cache module +;; buffer cache module (defconst elmo-buffer-cache-name " *elmo cache*") (defvar elmo-buffer-cache nil - "Message cache. (old ... new) order alist with association - ((\"folder\" message \"message-id\") . cache-buffer)") + "Message cache. (old ... new) order alist. +With association ((\"folder\" message \"message-id\") . cache-buffer).") (defmacro elmo-buffer-cache-buffer-get (entry) (` (cdr (, entry)))) @@ -398,7 +398,7 @@ If KBYTES is kilo bytes (This value must be float)." (setq elmo-buffer-cache (cdr top)))) (defun elmo-buffer-cache-add (fld-msg-id) - "Adding (fld-msg-id . buf) to the top of \"elmo-buffer-cache\". + "Adding (FLD-MSG-ID . buf) to the top of `elmo-buffer-cache'. Returning its cache buffer." (let ((len (length elmo-buffer-cache)) (buf nil)) @@ -431,9 +431,9 @@ Returning its cache buffer." (setq n (1+ n)))) (setq elmo-buffer-cache nil)) -;;; -;;; cache backend by Kenichi OKADA -;;; +;; +;; cache backend by Kenichi OKADA +;; (defsubst elmo-cache-get-folder-directory (spec) (if (file-name-absolute-p (nth 1 spec)) @@ -461,7 +461,7 @@ Returning its cache buffer." (defsubst elmo-cache-insert-header (file) "Insert the header of the article." (let ((beg 0) - insert-file-contents-pre-hook ; To avoid autoconv-xmas... + insert-file-contents-pre-hook ; To avoid autoconv-xmas... insert-file-contents-post-hook format-alist) (when (file-exists-p file) @@ -566,7 +566,7 @@ Returning its cache buffer." (expand-file-name (nth 1 (elmo-folder-get-spec folder)) (expand-file-name elmo-cache-dirname elmo-msgdb-dir))) - (if (string-match "^[+=$!]$" folder) ;; localdir, archive, localnews + (if (string-match "^[+=$!]$" folder) ; localdir, archive, localnews (setq subprefix folder) (setq subprefix (concat folder elmo-path-sep))) ;; include parent @@ -659,7 +659,7 @@ Returning its cache buffer." (mapcar '(lambda (msg) (elmo-cache-delete-msg spec msg locked)) msgs))))) -(defun elmo-cache-list-folder (spec); called by elmo-cache-search() +(defun elmo-cache-list-folder (spec) ; called by elmo-cache-search() (let ((killed (and elmo-use-killed-list (elmo-msgdb-killed-list-load (elmo-msgdb-expand-path spec)))) @@ -726,7 +726,7 @@ Returning its cache buffer." (expand-file-name (elmo-msgid-to-cache (cdr (assq (if same-number (car msgs) next-num) number-alist))) - dst-dir)) + dst-dir)) (if (and (setq msgs (cdr msgs)) (not same-number)) (setq next-num (1+ next-num)))) diff --git a/elmo/elmo-date.el b/elmo/elmo-date.el index 1a7a5cb..8a10d42 100644 --- a/elmo/elmo-date.el +++ b/elmo/elmo-date.el @@ -51,7 +51,7 @@ (defun elmo-date-get-datevec (description) (cond ((not elmo-date-match) - (error "date match is not available")) + (error "Date match is not available")) ((string-match "^[ \t]*\\([0-9]+\\)?[ \t]*\\([a-zA-Z]+\\)$" description) (let ((today (save-match-data diff --git a/elmo/elmo-dop.el b/elmo/elmo-dop.el index 0e13b7e..19e7a42 100644 --- a/elmo/elmo-dop.el +++ b/elmo/elmo-dop.el @@ -65,7 +65,7 @@ even an operation concerns the unplugged folder." (setq queue (cdr queue))) (when (> count 0) (if (elmo-y-or-n-p - (format "%d pending operation(s) exists. Perform now?" count) + (format "%d pending operation(s) exists. Perform now? " count) (not elmo-dop-flush-confirm) t) (progn (message "") @@ -107,7 +107,7 @@ even an operation concerns the unplugged folder." (when (and (string= func "create-folder-maybe") (elmo-y-or-n-p (format - "Create folder %s failed. Abort creating?" + "Create folder %s failed. Abort creating? " folder) (not elmo-dop-flush-confirm) t)) (elmo-dop-save-pending-messages folder) @@ -119,7 +119,7 @@ even an operation concerns the unplugged folder." performed num) (sit-for 1) ; (elmo-dop-queue-save))) - (if (elmo-y-or-n-p "Clear all pending operations?" + (if (elmo-y-or-n-p "Clear all pending operations? " (not elmo-dop-flush-confirm) t) (let ((queue elmo-dop-queue)) (while queue @@ -315,10 +315,10 @@ even an operation concerns the unplugged folder." matched) (if (eq (elmo-folder-get-type folder) 'imap4) (progn -;; (while append-list -;; (if (setq matched (car (rassoc (car append-list) number-alist))) -;; (setq msgs (delete matched msgs))) -;; (setq append-list (cdr append-list))) +;;; (while append-list +;;; (if (setq matched (car (rassoc (car append-list) number-alist))) +;;; (setq msgs (delete matched msgs))) +;;; (setq append-list (cdr append-list))) (if msgs (elmo-dop-queue-append folder func-name msgs))) ;; maildir... XXX hard coding..... @@ -379,7 +379,7 @@ even an operation concerns the unplugged folder." (when resume ;; Resume msgdb changed by elmo-dop-msgdb-create. (let* ((resumed-list (elmo-dop-append-list-load folder t)) - (number-alist (elmo-msgdb-number-load + (number-alist (elmo-msgdb-number-load (elmo-msgdb-expand-path folder))) (appendings append-list) pair dels) @@ -390,7 +390,7 @@ even an operation concerns the unplugged folder." (setq appendings (cdr appendings))) (elmo-dop-append-list-save folder resumed-list t))) (while appendings - (let* ((seen-list (elmo-msgdb-seen-load + (let* ((seen-list (elmo-msgdb-seen-load (elmo-msgdb-expand-path folder)))) (setq failure nil) (setq file-string (elmo-get-file-string ; message string diff --git a/elmo/elmo-imap4.el b/elmo/elmo-imap4.el index 7328dc5..dcb2f31 100644 --- a/elmo/elmo-imap4.el +++ b/elmo/elmo-imap4.el @@ -79,7 +79,7 @@ (defvar elmo-imap4-extra-namespace-alist '(("^{.*/nntp}.*$" . ".")) ; Default is for UW's remote nntp mailbox... - "Extra namespace alist. A list of cons cell like: (REGEXP . DELIMITER) ") + "Extra namespace alist. A list of cons cell like: (REGEXP . DELIMITER).") (defvar elmo-imap4-default-hierarchy-delimiter "/") (defvar elmo-imap4-server-capability nil) @@ -221,7 +221,7 @@ Debug information is inserted in the buffer \"*IMAP4 DEBUG*\"") (elmo-imap4-response-value (, response) 'bye))))) (defmacro elmo-imap4-response-bodydetail-text (response) - "Returns text of BODY[section]" + "Returns text of BODY[section]." (` (nth 3 (assq 'bodydetail (, response))))) ;;; Session commands. @@ -604,7 +604,7 @@ BUFFER must be a single-byte buffer." (elmo-imap4-mailbox (elmo-imap4-spec-mailbox spec))))))) (defun elmo-imap4-rename-folder (old-spec new-spec) - ;;(elmo-imap4-send-command-wait session "close") +;;;(elmo-imap4-send-command-wait session "close") (elmo-imap4-send-command-wait (elmo-imap4-get-session old-spec) (list "rename " @@ -705,13 +705,13 @@ Returns t if selecting folder succeed. Otherwise, nil is returned." result))) (defun elmo-imap4-check-validity (spec validity-file) - ;; Not used. -; (elmo-imap4-send-command-wait -; (elmo-imap4-get-session spec) -; (list "status " -; (elmo-imap4-mailbox -; (elmo-imap4-spec-mailbox spec)) -; " (uidvalidity)"))) +;;; Not used. +;;;(elmo-imap4-send-command-wait +;;;(elmo-imap4-get-session spec) +;;;(list "status " +;;; (elmo-imap4-mailbox +;;; (elmo-imap4-spec-mailbox spec)) +;;; " (uidvalidity)"))) ) (defun elmo-imap4-sync-validity (spec validity-file) @@ -1196,11 +1196,11 @@ If optional argument UNMARK is non-nil, unmark." (accept-process-output process 1)) (set-process-filter process 'elmo-imap4-arrival-filter) (set-process-sentinel process 'elmo-imap4-sentinel) -;; (while (and (memq (process-status process) '(open run)) -;; (eq elmo-imap4-status 'initial)) -;; (message "Waiting for server response...") -;; (accept-process-output process 1)) -;; (message "") +;;; (while (and (memq (process-status process) '(open run)) +;;; (eq elmo-imap4-status 'initial)) +;;; (message "Waiting for server response...") +;;; (accept-process-output process 1)) +;;; (message "") (unless (memq elmo-imap4-status '(nonauth auth)) (signal 'elmo-open-error (list 'elmo-network-initialize-session))) @@ -1452,7 +1452,7 @@ If optional argument UNMARK is non-nil, unmark." (let ((session (elmo-imap4-get-session spec)) response) ;; commit. -; (elmo-imap4-commit spec) +;;; (elmo-imap4-commit spec) (with-current-buffer (elmo-network-session-buffer session) (setq elmo-imap4-status-callback nil) (setq elmo-imap4-status-callback-data nil)) @@ -1570,7 +1570,7 @@ Return nil if no complete line has arrived." nil (goto-char (+ pos len)) (buffer-substring pos (+ pos len)))))) - ;(list ' pos (+ pos len)))))) +;;; (list ' pos (+ pos len)))))) (defsubst elmo-imap4-parse-string () (cond ((eq (char-after (point)) ?\") diff --git a/elmo/elmo-internal.el b/elmo/elmo-internal.el index 69a8fc1..dd87b18 100644 --- a/elmo/elmo-internal.el +++ b/elmo/elmo-internal.el @@ -139,7 +139,7 @@ mark-alist (elmo-msgdb-overview-entity-get-number entity) - ;(nth 0 entity) +;;; (nth 0 entity) (or (elmo-msgdb-global-mark-get (elmo-msgdb-overview-entity-get-id entity)) diff --git a/elmo/elmo-localdir.el b/elmo/elmo-localdir.el index 4b5568f..33dc9ee 100644 --- a/elmo/elmo-localdir.el +++ b/elmo/elmo-localdir.el @@ -337,7 +337,7 @@ (defun elmo-localdir-delete-folder (spec) (let* ((dir (elmo-localdir-get-folder-directory spec))) (if (not (file-directory-p dir)) - (error "no such directory: %s" dir) + (error "No such directory: %s" dir) (elmo-delete-directory dir t) t))) @@ -346,9 +346,9 @@ (new (elmo-localdir-get-folder-directory new-spec)) (new-dir (directory-file-name (file-name-directory new)))) (if (not (file-directory-p old)) - (error "no such directory: %s" old) + (error "No such directory: %s" old) (if (file-exists-p new) - (error "already exists directory: %s" new) + (error "Already exists directory: %s" new) (if (not (file-exists-p new-dir)) (elmo-make-directory new-dir)) (rename-file old new) diff --git a/elmo/elmo-maildir.el b/elmo/elmo-maildir.el index 19663aa..049c38f 100644 --- a/elmo/elmo-maildir.el +++ b/elmo/elmo-maildir.el @@ -105,7 +105,7 @@ This variable should not be used in elsewhere.") "^[^.].*$" t)))) (defun elmo-maildir-update-current (spec) - "Move all new msgs to cur in the maildir" + "Move all new msgs to cur in the maildir." (let* ((maildir (elmo-maildir-get-folder-directory spec)) (news (directory-files (expand-file-name "new" maildir) @@ -122,7 +122,7 @@ This variable should not be used in elsewhere.") (setq news (cdr news))))) (defun elmo-maildir-set-mark (filename mark) - "Mark the file in the maildir. MARK is a character." + "Mark the FILENAME file in the maildir. MARK is a character." (if (string-match "^\\([^:]+:[12],\\)\\(.*\\)$" filename) (let ((flaglist (string-to-char-list (elmo-match-string 2 filename)))) @@ -136,7 +136,7 @@ This variable should not be used in elsewhere.") (concat filename ":2," (char-to-string mark))))) (defun elmo-maildir-delete-mark (filename mark) - "Mark the file in the maildir. MARK is a character." + "Mark the FILENAME file in the maildir. MARK is a character." (if (string-match "^\\([^:]+:2,\\)\\(.*\\)$" filename) (let ((flaglist (string-to-char-list (elmo-match-string 2 filename)))) @@ -293,7 +293,8 @@ file name for maildir directories." (unless (file-exists-p (file-name-directory filename)) (make-directory (file-name-directory filename))) (while (file-exists-p filename) - ;; (sleep-for 2) ; I don't want to wait. +;;; I don't want to wait. +;;; (sleep-for 2) (setq filename (expand-file-name (concat "tmp/" (elmo-maildir-make-unique-string)) diff --git a/elmo/elmo-msgdb.el b/elmo/elmo-msgdb.el index 9abc0e2..5d314ca 100644 --- a/elmo/elmo-msgdb.el +++ b/elmo/elmo-msgdb.el @@ -132,7 +132,7 @@ FOLDER should be a sring of folder name or folder spec." (defsubst elmo-msgdb-append-element (list element) (if list - ;(append list (list element)) +;;; (append list (list element)) (nconc list (list element)) ;; list is nil (list element))) @@ -272,12 +272,12 @@ FOLDER should be a sring of folder name or folder spec." ret-val)) (defun elmo-msgdb-mark-append (alist id mark) - "Append mark" + "Append mark." (setq alist (elmo-msgdb-append-element alist (list id mark)))) (defun elmo-msgdb-mark-alist-to-seen-list (number-alist mark-alist seen-marks) - "Make seen-list from mark-alist" + "Make seen-list from MARK-ALIST." (let ((seen-mark-list (string-to-char-list seen-marks)) ret-val ent) (while number-alist @@ -421,18 +421,18 @@ header separator." number-list)) (string-to-int (elmo-filter-value condition))))) ((string= key "first") - (setq result (< (- + (setq result (< (- (length number-list) (length (memq (elmo-msgdb-overview-entity-get-number entity) number-list))) (string-to-int (elmo-filter-value condition))))) ((string= key "from") - (setq result (string-match + (setq result (string-match (elmo-filter-value condition) (elmo-msgdb-overview-entity-get-from entity)))) ((string= key "subject") - (setq result (string-match + (setq result (string-match (elmo-filter-value condition) (elmo-msgdb-overview-entity-get-subject entity)))) ((string= key "to") @@ -500,8 +500,8 @@ content of MSGDB is changed." (if (and (not reserve-cache) message-id) (elmo-cache-delete message-id folder (car msg-list))) - ;; This is no good!!!! - ;(setq overview (delete (assoc message-id overview) overview)) +;;; This is no good!!!! +;;; (setq overview (delete (assoc message-id overview) overview)) (setq overview (delq (setq ov-entity @@ -554,7 +554,7 @@ content of MSGDB is changed." (defsubst elmo-msgdb-overview-entity-set-number (entity number) (and entity (aset (cdr entity) 0 number)) entity) - ;(setcar (cadr entity) number) entity) +;;;(setcar (cadr entity) number) entity) (defsubst elmo-msgdb-overview-entity-set-from (entity from) (and entity (aset (cdr entity) 2 from)) @@ -821,7 +821,7 @@ Header region is supposed to be narrowed." (if (not (file-directory-p old)) () (if (file-exists-p new) - (error "already exists directory: %s" new) + (error "Already exists directory: %s" new) (if (not (file-exists-p new-dir)) (elmo-make-directory new-dir)) (rename-file old new))))) diff --git a/elmo/elmo-multi.el b/elmo/elmo-multi.el index 6182de0..0d00536 100644 --- a/elmo/elmo-multi.el +++ b/elmo/elmo-multi.el @@ -272,7 +272,7 @@ (function (lambda (x) (+ (* elmo-multi-divide-number cur-number) x))) - (elmo-list-folder-important + (elmo-list-folder-important (car folders) (car split-number-alist)))) folders (cdr folders))) diff --git a/elmo/elmo-net.el b/elmo/elmo-net.el index 5b946fa..7b3129e 100644 --- a/elmo/elmo-net.el +++ b/elmo/elmo-net.el @@ -30,6 +30,8 @@ (require 'elmo-util) (require 'elmo-vars) +;;; Code: +;; (eval-and-compile (luna-define-class elmo-network-session () (name host @@ -65,8 +67,8 @@ (luna-define-method elmo-network-close-session ((session elmo-network-session)) (when (elmo-network-session-process-internal session) -; (memq (process-status (elmo-network-session-process-internal session)) -; '(open run)) +;;; (memq (process-status (elmo-network-session-process-internal session)) +;;; '(open run)) (kill-buffer (process-buffer (elmo-network-session-process-internal session))) (delete-process (elmo-network-session-process-internal session)))) @@ -164,7 +166,7 @@ PORT is the port number of the service. USER is the user-id for the authenticate. AUTH is the authenticate method name (symbol). STREAM-TYPE is the stream type (See also `elmo-network-stream-type-alist'). -Returns a process object. if making session failed, returns nil." +Returns a process object. if making session failed, returns nil." (let ((session (luna-make-entity class :name name diff --git a/elmo/elmo-nntp.el b/elmo/elmo-nntp.el index 4917e71..4b0aeed 100644 --- a/elmo/elmo-nntp.el +++ b/elmo/elmo-nntp.el @@ -97,7 +97,7 @@ Don't cache if nil.") (setq elmo-nntp-server-command-alist (nconc elmo-nntp-server-command-alist (list (cons - (cons + (cons (elmo-network-session-host-internal (, session)) (elmo-network-session-port-internal (, session))) (setq entry @@ -185,13 +185,13 @@ Don't cache if nil.") (with-current-buffer (elmo-network-session-buffer session) (setq elmo-nntp-read-point (point-min)) (or (elmo-nntp-read-response session t) - (error "cannot open network")) + (error "Cannot open network")) (when (eq (elmo-network-stream-type-symbol (elmo-network-session-stream-type-internal session)) 'starttls) (elmo-nntp-send-command session "starttls") (or (elmo-nntp-read-response session) - (error "cannot open starttls session")) + (error "Cannot open starttls session")) (starttls-negotiate (elmo-network-session-process-internal session))))) @@ -228,7 +228,7 @@ Don't cache if nil.") (defun elmo-nntp-send-mode-reader (session) (elmo-nntp-send-command session "mode reader") (if (null (elmo-nntp-read-response session t)) - (error "mode reader failed"))) + (error "Mode reader failed"))) (defun elmo-nntp-send-command (session command &optional noerase) (with-current-buffer (elmo-network-session-buffer session) @@ -260,8 +260,8 @@ Don't cache if nil.") (if (looking-at "[23][0-9]+ .*$") (progn (setq response-continue nil) (setq elmo-nntp-read-point match-end) - (setq response - (if response + (setq response + (if response (concat response "\n" response-string) response-string))) (if (looking-at "[^23][0-9]+ .*$") @@ -272,7 +272,7 @@ Don't cache if nil.") (if not-command (setq response-continue nil)) (setq response - (if response + (if response (concat response "\n" response-string) response-string))) (setq elmo-nntp-read-point match-end))) @@ -295,7 +295,7 @@ Don't cache if nil.") session)) (goto-char elmo-nntp-read-point)) (elmo-delete-cr - (buffer-substring elmo-nntp-read-point + (buffer-substring elmo-nntp-read-point (- (point) 3))))) (defun elmo-nntp-read-body (session outbuf) @@ -415,7 +415,7 @@ Don't cache if nil.") (setq regexp (format "^\\(%s[^. ]+\\)\\([. ]\\).*\n" (if (and (elmo-nntp-spec-group spec) - (null (string= + (null (string= (elmo-nntp-spec-group spec) ""))) (concat (elmo-nntp-spec-group spec) "\\.") ""))) @@ -455,7 +455,7 @@ Don't cache if nil.") (setq append-serv (concat append-serv ":" (int-to-string (elmo-nntp-spec-port spec))))) - (unless (eq (elmo-network-stream-type-symbol + (unless (eq (elmo-network-stream-type-symbol (elmo-nntp-spec-stream-type spec)) elmo-default-nntp-stream-type) (setq append-serv @@ -466,7 +466,7 @@ Don't cache if nil.") (if (consp fld) (list (concat "-" (car fld) (and (elmo-nntp-spec-username spec) - (concat + (concat ":" (elmo-nntp-spec-username spec))) (and append-serv (concat append-serv)))) @@ -527,12 +527,12 @@ Don't cache if nil.") (defun elmo-nntp-max-of-folder (spec) (let ((killed-list (and elmo-use-killed-list - (elmo-msgdb-killed-list-load + (elmo-msgdb-killed-list-load (elmo-msgdb-expand-path spec)))) end-num entry) (if elmo-nntp-groups-async (if (setq entry - (elmo-get-hash-val + (elmo-get-hash-val (concat (elmo-nntp-spec-group spec) (elmo-nntp-folder-postfix (elmo-nntp-spec-username spec) @@ -557,9 +557,9 @@ Don't cache if nil.") (format "group %s" (elmo-nntp-spec-group spec))) (setq response (elmo-nntp-read-response session)) - (if (and response - (string-match - "211 \\([0-9]+\\) \\([0-9]+\\) \\([0-9]+\\) [^.].+$" + (if (and response + (string-match + "211 \\([0-9]+\\) \\([0-9]+\\) \\([0-9]+\\) [^.].+$" response)) (progn (setq end-num (string-to-int @@ -601,12 +601,12 @@ Don't cache if nil.") (setq ov-list (elmo-nntp-parse-overview-string str)) (while ov-list (setq ov-entity (car ov-list)) - ;; INN bug?? -; (if (or (> (setq num (string-to-int (aref ov-entity 0))) -; 99999) -; (<= num 0)) -; (setq num 0)) -; (setq num (int-to-string num)) +;;; INN bug?? +;;; (if (or (> (setq num (string-to-int (aref ov-entity 0))) +;;; 99999) +;;; (<= num 0)) +;;; (setq num 0)) +;;; (setq num (int-to-string num)) (setq num (string-to-int (aref ov-entity 0))) (when (or (null numlist) (memq num numlist)) @@ -840,7 +840,7 @@ Don't cache if nil.") (forward-line 1) (setq beg (point)) (setq ret-val (nconc ret-val (list ret-list)))) -; (kill-buffer tmp-buffer) +;;; (kill-buffer tmp-buffer) ret-val))) (defun elmo-nntp-get-newsgroup-by-msgid (msgid server user port type) @@ -872,11 +872,11 @@ Don't cache if nil.") (replace-match "") (forward-line)))))))) -;(defun elmo-msgdb-nntp-overview-create-range (spec beg end mark) -; (elmo-nntp-overview-create-range hostname beg end mark folder))) +;;(defun elmo-msgdb-nntp-overview-create-range (spec beg end mark) +;; (elmo-nntp-overview-create-range hostname beg end mark folder))) -;(defun elmo-msgdb-nntp-max-of-folder (spec) -; (elmo-nntp-max-of-folder hostname folder))) +;;(defun elmo-msgdb-nntp-max-of-folder (spec) +;; (elmo-nntp-max-of-folder hostname folder))) (defun elmo-nntp-append-msg (spec string &optional msg no-see)) @@ -905,7 +905,7 @@ Don't cache if nil.") (run-hooks 'elmo-nntp-post-pre-hook) (elmo-nntp-send-buffer session content-buf) (elmo-nntp-send-command session ".") - ;;(elmo-nntp-read-response buffer process t) +;;; (elmo-nntp-read-response buffer process t) (if (not (string-match "^2" (setq response (elmo-nntp-read-raw-response session)))) @@ -1037,7 +1037,7 @@ Returns a list of cons cells like (NUMBER . VALUE)" (if from-msgs (elmo-list-filter from-msgs result) result))) - (t + (t (let ((val (elmo-filter-value condition)) (negative (eq (elmo-filter-type condition) 'unmatch)) (case-fold-search t) @@ -1152,7 +1152,7 @@ Returns a list of cons cells like (NUMBER . VALUE)" (let* ((received 0) (last-point (point-min))) (with-current-buffer (elmo-network-session-buffer session) - (accept-process-output + (accept-process-output (elmo-network-session-process-internal session) 1) (discard-input) ;; Wait for all replies. @@ -1237,7 +1237,7 @@ Returns a list of cons cells like (NUMBER . VALUE)" ;; order to avoid deadlocks. (when (or (null articles) ;All requests have been sent. (zerop (% count elmo-nntp-header-fetch-chop-length))) - (accept-process-output + (accept-process-output (elmo-network-session-process-internal session) 1) (discard-input) (while (progn diff --git a/elmo/elmo-pop3.el b/elmo/elmo-pop3.el index 70e9e66..1a82f44 100644 --- a/elmo/elmo-pop3.el +++ b/elmo/elmo-pop3.el @@ -358,10 +358,10 @@ ;; UIDL (elmo-pop3-send-command process "uidl") (unless (elmo-pop3-read-response process) - (error "UIDL failed.")) + (error "UIDL failed")) (unless (setq response (elmo-pop3-read-contents (current-buffer) process)) - (error "UIDL failed.")) + (error "UIDL failed")) (elmo-pop3-parse-uidl-response response))))) (defun elmo-pop3-read-contents (buffer process) @@ -530,7 +530,7 @@ (elmo-pop3-send-command process (format "top %s 0" (car articles)) 'no-erase) - ;; (accept-process-output process 1) +;;; (accept-process-output process 1) (setq articles (cdr articles)) (setq count (1+ count)) ;; Every 200 requests we have to read the stream in @@ -555,7 +555,7 @@ 'elmo-pop3-retrieve-headers "Getting headers..." (/ (* received 100) number)))) (accept-process-output process 1) - ;(accept-process-output process) +;;; (accept-process-output process) (discard-input)))) ;; Remove all "\r"'s. (goto-char (point-min)) diff --git a/elmo/elmo-util.el b/elmo/elmo-util.el index c43eaac..365ffd2 100644 --- a/elmo/elmo-util.el +++ b/elmo/elmo-util.el @@ -157,7 +157,7 @@ File content is encoded with MIME-CHARSET." (if (file-writable-p filename) (progn (when mime-charset - ;;(elmo-set-buffer-multibyte default-enable-multibyte-characters) +;;; (elmo-set-buffer-multibyte default-enable-multibyte-characters) (encode-mime-charset-region (point-min) (point-max) mime-charset)) (as-binary-output-file (write-region (point-min) (point-max) filename nil 'no-msg))) @@ -169,7 +169,7 @@ Directory of the file is created if it doesn't exist. File content is encoded with MIME-CHARSET." (elmo-set-work-buf (prin1 object (current-buffer)) - ;;(princ "\n" (current-buffer)) +;;;(princ "\n" (current-buffer)) (elmo-save-buffer filename mime-charset))) (defsubst elmo-imap4-decode-folder-string (string) @@ -324,9 +324,9 @@ File content is encoded with MIME-CHARSET." ) (if (file-name-absolute-p fld-name) (setq path (expand-file-name fld-name)) +;;; (setq path (expand-file-name fld-name +;;; elmo-localdir-folder-path)) (setq path fld-name)) - ;(setq path (expand-file-name fld-name - ;elmo-localdir-folder-path))) (list (if (elmo-folder-maildir-p folder) 'maildir 'localdir) path)))) @@ -749,9 +749,9 @@ Return value is a cons cell of (STRUCTURE . REST)" (erase-buffer) (prin1 elmo-passwd-alist tmp-buffer) (princ "\n" tmp-buffer) -; (if (and (file-exists-p filename) -; (not (equal 384 (file-modes filename)))) -; (error "%s is not safe.chmod 600 %s!" filename filename)) +;;; (if (and (file-exists-p filename) +;;; (not (equal 384 (file-modes filename)))) +;;; (error "%s is not safe.chmod 600 %s!" filename filename)) (if (file-writable-p filename) (progn (write-region (point-min) (point-max) @@ -844,7 +844,7 @@ Return value is a cons cell of (STRUCTURE . REST)" ;; from subr.el (defun elmo-replace-in-string (str regexp newtext &optional literal) - "Replaces all matches in STR for REGEXP with NEWTEXT string. + "Replace all matches in STR for REGEXP with NEWTEXT string. And returns the new string. Optional LITERAL non-nil means do a literal replacement. Otherwise treat \\ in NEWTEXT string as special: @@ -1191,10 +1191,12 @@ Otherwise treat \\ in NEWTEXT string as special: (cond ((eq (elmo-folder-get-type folder1) 'imap4) (let ((spec1 (elmo-folder-get-spec folder1)) (spec2 (elmo-folder-get-spec folder2))) - (and ;(elmo-imap4-identical-name-space-p ;; No use. - ; (nth 1 spec1) (nth 1 spec2)) + (and +;;; No use. +;;; (elmo-imap4-identical-name-space-p +;;; (nth 1 spec1) (nth 1 spec2)) (string= (elmo-imap4-spec-hostname spec1) - (elmo-imap4-spec-hostname spec2)) ; hostname + (elmo-imap4-spec-hostname spec2)) ; hostname (string= (elmo-imap4-spec-username spec1) (elmo-imap4-spec-username spec2))))) ; username (t @@ -1327,7 +1329,8 @@ Otherwise treat \\ in NEWTEXT string as special: (list 'makunbound (list 'intern string hashtable)))) (defmacro elmo-unintern (string) - ;; Emacs 19.28 or earlier does not have unintern. + "`unintern' symbol named STRING, When can use `unintern'. +Emacs 19.28 or earlier does not have `unintern'." (static-if (fboundp 'unintern) (list 'unintern string))) diff --git a/elmo/mmelmo.el b/elmo/mmelmo.el index d04e5a4..14b24ff 100644 --- a/elmo/mmelmo.el +++ b/elmo/mmelmo.el @@ -253,11 +253,11 @@ size: size of the entity." (buffer-substring (mime-buffer-entity-body-start-internal entity) (mime-buffer-entity-body-end-internal entity)))) -;(luna-define-method mime-entity-content ((entity mime-elmo-entity)) -; (mime-decode-string -; (with-current-buffer (mime-buffer-entity-buffer-internal entity) -; (buffer-substring (mime-buffer-entity-body-start-internal entity) -; (mime-buffer-entity-body-end-internal entity))) -; (mime-entity-encoding entity))) +;;(luna-define-method mime-entity-content ((entity mime-elmo-entity)) +;; (mime-decode-string +;; (with-current-buffer (mime-buffer-entity-buffer-internal entity) +;; (buffer-substring (mime-buffer-entity-body-start-internal entity) +;; (mime-buffer-entity-body-end-internal entity))) +;; (mime-entity-encoding entity))) ;;; mmelmo.el ends here