2001-02-06 02:00:00 ShengHuo ZHU <zsh@cs.rochester.edu>
authorShengHuo ZHU <zsh@cs.rochester.edu>
Tue, 6 Feb 2001 07:27:29 +0000 (07:27 +0000)
committerShengHuo ZHU <zsh@cs.rochester.edu>
Tue, 6 Feb 2001 07:27:29 +0000 (07:27 +0000)
* gnus-start.el (gnus-read-descriptions-file): Use
gnus-group-name-charset and gnus-group-charset-alist.

lisp/ChangeLog
lisp/gnus-start.el

index dcf5ff7..9cc0642 100644 (file)
@@ -1,3 +1,8 @@
+2001-02-06 02:00:00  ShengHuo ZHU  <zsh@cs.rochester.edu>
+
+       * gnus-start.el (gnus-read-descriptions-file): Use
+       gnus-group-name-charset and gnus-group-charset-alist.
+
 2001-02-04 23:00:00  ShengHuo ZHU  <zsh@cs.rochester.edu>
 
        * gnus-sum.el (gnus-summary-mark-as-processable): Understand
index 80ad0d3..a7a334f 100644 (file)
@@ -2634,16 +2634,20 @@ If FORCE is non-nil, the .newsrc file is read."
            (skip-chars-forward " \t")
            ;; ...  which leads to this line being effectively ignored.
            (when (symbolp group)
-             (let ((str (buffer-substring
-                         (point) (progn (end-of-line) (point))))
-                   (coding
-                    (and (or (featurep 'xemacs)
-                             (and (boundp 'enable-multibyte-characters)
-                                  enable-multibyte-characters))
-                         (fboundp 'gnus-mule-get-coding-system)
-                         (gnus-mule-get-coding-system (symbol-name group)))))
-               (when coding
-                 (setq str (mm-decode-coding-string str (car coding))))
+             (let* ((str (buffer-substring
+                          (point) (progn (end-of-line) (point))))
+                    (name (symbol-name group))
+                    (charset
+                    (or (gnus-group-name-charset method name)
+                        (let ((alist gnus-group-charset-alist)
+                              elem charset)
+                          (while (setq elem (pop alist))
+                            (when (and name (string-match (car elem) name))
+                              (setq alist nil
+                                    charset (cadr elem))))
+                          charset))))
+               (when (and str charset (featurep 'mule))
+                 (setq str (mm-decode-coding-string str charset)))
                (set group str)))
            (forward-line 1))))
       (gnus-message 5 "Reading descriptions file...done")