diff -ruN --exclude=*~ --exclude=*.elc --exclude=*.orig xemacs/lisp/gnus/ChangeLog.semi-patch /usr/local/lib/xemacs/packages/lisp/gnus/ChangeLog.semi-patch
--- xemacs/lisp/gnus/ChangeLog.semi-patch	Thu Jan  1 09:00:00 1970
+++ /usr/local/lib/xemacs/packages/lisp/gnus/ChangeLog.semi-patch	Sat Aug  2 01:18:50 1997
@@ -0,0 +1,49 @@
+1997-06-18  MORIOKA Tomohiko  <morioka@jaist.ac.jp>
+
+	* gnus-sum.el (gnus-structured-field-decoder): New variable.
+
+	(gnus-get-newsgroup-headers, gnus-nov-parse-line): Use
+	`gnus-structured-field-decoder' for Subject field.
+
+1997-06-13  MORIOKA Tomohiko  <morioka@jaist.ac.jp>
+
+	* gnus-sum.el (gnus-unstructured-field-decoder): New variable.
+	
+	(gnus-get-newsgroup-headers, gnus-nov-parse-line): Use
+	`gnus-unstructured-field-decoder' for Subject field instead of
+	`gnus-header-decoder'; Variable `gnus-header-decoder' was
+	abolished.
+
+Fri May 16 06:15:11 1997  MORIOKA Tomohiko  <morioka@jaist.ac.jp>
+
+	* nnheader.el (nnheader-find-file-noselect): bind
+	`coding-system-for-read' with `nnheader-file-coding-system' for
+	Emacs/mule and XEmacs/mule.
+
+Sun May  4 14:52:50 1997  MORIOKA Tomohiko  <morioka@jaist.ac.jp>
+
+	* gnus-sum.el (gnus-header-decoder): New variable.
+
+	(gnus-get-newsgroup-headers): Use `gnus-header-decoder' for From
+	and Subject field.
+
+	(gnus-nov-parse-line): Use `gnus-header-decoder' for From and
+	Subject field.
+
+	* nnmail.el (nnmail-file-coding-system): New variable.
+
+	(nnmail-find-file): bind `coding-system-for-read' with
+	`nnmail-file-coding-system' for Emacs/mule and XEmacs/mule.
+
+	(nnmail-write-region): bind `coding-system-for-write' with
+	`nnmail-file-coding-system' for Emacs/mule and XEmacs/mule.
+
+	* nnheader.el (nnheader-file-coding-system): New variable.
+
+	(nnheader-insert-file-contents): bind `coding-system-for-read'
+	with `nnheader-file-coding-system' for Emacs/mule and XEmacs/mule.
+
+	* nntp.el (nntp-coding-system-for-read): New variable.
+
+	(nntp-open-connection): bind `coding-system-for-read' with
+	`nntp-coding-system-for-read' for Emacs/mule and XEmacs/mule.
diff -ruN --exclude=*~ --exclude=*.elc --exclude=*.orig xemacs/lisp/gnus/gnus-sum.el /usr/local/lib/xemacs/packages/lisp/gnus/gnus-sum.el
--- xemacs/lisp/gnus/gnus-sum.el	Mon Jul 21 05:34:47 1997
+++ /usr/local/lib/xemacs/packages/lisp/gnus/gnus-sum.el	Sat Aug  2 01:18:51 1997
@@ -617,6 +617,17 @@
   :group 'gnus-summary-visual
   :type 'hook)
 
+;; 1997/5/4 by MORIOKA Tomohiko <morioka@jaist.ac.jp>
+(defcustom gnus-structured-field-decoder 'identity
+  "Function to decode non-ASCII characters in structured field for summary."
+  :group 'gnus-various
+  :type 'function)
+
+(defcustom gnus-unstructured-field-decoder 'identity
+  "Function to decode non-ASCII characters in unstructured field for summary."
+  :group 'gnus-various
+  :type 'function)
+
 (defcustom gnus-parse-headers-hook
   (list 'gnus-hack-decode-rfc1522 'gnus-decode-rfc1522)
   "*A hook called before parsing the headers."
@@ -4146,12 +4157,18 @@
 	    (progn
 	      (goto-char p)
 	      (if (search-forward "\nsubject: " nil t)
-		  (nnheader-header-value) "(none)"))
+		  ;; 1997/5/4 by MORIOKA Tomohiko <morioka@jaist.ac.jp>
+		  (funcall
+		   gnus-unstructured-field-decoder (nnheader-header-value))
+		"(none)"))
 	    ;; From.
 	    (progn
 	      (goto-char p)
 	      (if (search-forward "\nfrom: " nil t)
-		  (nnheader-header-value) "(nobody)"))
+		  ;; 1997/5/4 by MORIOKA Tomohiko <morioka@jaist.ac.jp>
+		  (funcall
+		   gnus-structured-field-decoder (nnheader-header-value))
+		"(nobody)"))
 	    ;; Date.
 	    (progn
 	      (goto-char p)
@@ -4286,8 +4303,11 @@
 	  (setq header
 		(vector
 		 number			; number
-		 (gnus-nov-field)	; subject
-		 (gnus-nov-field)	; from
+		 ;; 1997/5/4 by MORIOKA Tomohiko <morioka@jaist.ac.jp>
+		 (funcall
+		  gnus-unstructured-field-decoder (gnus-nov-field)) ; subject
+		 (funcall
+		  gnus-structured-field-decoder (gnus-nov-field))   ; from
 		 (gnus-nov-field)	; date
 		 (setq id (or (gnus-nov-field)
 			      (nnheader-generate-fake-message-id))) ; id
diff -ruN --exclude=*~ --exclude=*.elc --exclude=*.orig xemacs/lisp/gnus/gnus.el /usr/local/lib/xemacs/packages/lisp/gnus/gnus.el
--- xemacs/lisp/gnus/gnus.el	Mon Jul 21 05:34:47 1997
+++ /usr/local/lib/xemacs/packages/lisp/gnus/gnus.el	Wed Aug 13 01:46:09 1997
@@ -244,6 +244,11 @@
 (defconst gnus-version (format "Gnus v%s" gnus-version-number)
   "Version string for this version of Gnus.")
 
+;; 1997/05/12 by MORIOKA Tomohiko <morioka@jaist.ac.jp>
+(defconst gnus-version (format "Gnus v%s + SEMI patch (r2.2)"
+			       gnus-version-number)
+  "Version string for this version of Gnus.")
+
 (defcustom gnus-inhibit-startup-message nil
   "If non-nil, the startup message will not be displayed.
 This variable is used before `.gnus.el' is loaded, so it should
diff -ruN --exclude=*~ --exclude=*.elc --exclude=*.orig xemacs/lisp/gnus/nnfolder.el /usr/local/lib/xemacs/packages/lisp/gnus/nnfolder.el
--- xemacs/lisp/gnus/nnfolder.el	Mon Jul 21 05:34:48 1997
+++ /usr/local/lib/xemacs/packages/lisp/gnus/nnfolder.el	Fri Aug 15 01:47:25 1997
@@ -283,8 +283,12 @@
 (deffoo nnfolder-request-list (&optional server)
   (nnfolder-possibly-change-group nil server)
   (save-excursion
-    (nnmail-find-file nnfolder-active-file)
-    (setq nnfolder-group-alist (nnmail-get-active))
+    ;; 1997/8/14 by MORIOKA Tomohiko
+    ;;    for XEmacs/mule.
+    (let ((nnmail-file-coding-system nnmail-active-file-coding-system)
+	  (pathname-coding-system 'binary)) ; for XEmacs/mule
+      (nnmail-find-file nnfolder-active-file)
+      (setq nnfolder-group-alist (nnmail-get-active)))
     t))
 
 (deffoo nnfolder-request-newgroups (date &optional server)
@@ -500,46 +504,49 @@
   ;; Change group.
   (when (and group
 	     (not (equal group nnfolder-current-group)))
-    (nnmail-activate 'nnfolder)
-    (when (and (not (assoc group nnfolder-group-alist))
-	       (not (file-exists-p
-		     (nnfolder-group-pathname group))))
-      ;; The group doesn't exist, so we create a new entry for it.
-      (push (list group (cons 1 0)) nnfolder-group-alist)
-      (nnmail-save-active nnfolder-group-alist nnfolder-active-file))
-
-    (if dont-check
-	(setq nnfolder-current-group group
-	      nnfolder-current-buffer nil)
-      (let (inf file)
-	;; If we have to change groups, see if we don't already have the
-	;; folder in memory.  If we do, verify the modtime and destroy
-	;; the folder if needed so we can rescan it.
-	(setq nnfolder-current-buffer
-	      (nth 1 (assoc group nnfolder-buffer-alist)))
-
-	;; If the buffer is not live, make sure it isn't in the alist.  If it
-	;; is live, verify that nobody else has touched the file since last
-	;; time.
-	(when (and nnfolder-current-buffer
-		   (not (gnus-buffer-live-p nnfolder-current-buffer)))
-	  (setq nnfolder-buffer-alist (delq inf nnfolder-buffer-alist)
-		nnfolder-current-buffer nil))
-
-	(setq nnfolder-current-group group)
-
-	(when (or (not nnfolder-current-buffer)
-		  (not (verify-visited-file-modtime nnfolder-current-buffer)))
-	  (save-excursion
-	    (setq file (nnfolder-group-pathname group))
-	    ;; See whether we need to create the new file.
-	    (unless (file-exists-p file)
-	      (gnus-make-directory (file-name-directory file))
-	      (nnmail-write-region 1 1 file t 'nomesg))
-	    (when (setq nnfolder-current-buffer (nnfolder-read-folder group))
-	      (set-buffer nnfolder-current-buffer)
-	      (push (list group nnfolder-current-buffer)
-		    nnfolder-buffer-alist))))))))
+    ;; 1997/8/14 by MORIOKA Tomohiko
+    ;;    for XEmacs/mule.
+    (let ((pathname-coding-system 'binary))
+      (nnmail-activate 'nnfolder)
+      (when (and (not (assoc group nnfolder-group-alist))
+		 (not (file-exists-p
+		       (nnfolder-group-pathname group))))
+	;; The group doesn't exist, so we create a new entry for it.
+	(push (list group (cons 1 0)) nnfolder-group-alist)
+	(nnmail-save-active nnfolder-group-alist nnfolder-active-file))
+      
+      (if dont-check
+	  (setq nnfolder-current-group group
+		nnfolder-current-buffer nil)
+	(let (inf file)
+	  ;; If we have to change groups, see if we don't already have the
+	  ;; folder in memory.  If we do, verify the modtime and destroy
+	  ;; the folder if needed so we can rescan it.
+	  (setq nnfolder-current-buffer
+		(nth 1 (assoc group nnfolder-buffer-alist)))
+	  
+	  ;; If the buffer is not live, make sure it isn't in the alist.  If it
+	  ;; is live, verify that nobody else has touched the file since last
+	  ;; time.
+	  (when (and nnfolder-current-buffer
+		     (not (gnus-buffer-live-p nnfolder-current-buffer)))
+	    (setq nnfolder-buffer-alist (delq inf nnfolder-buffer-alist)
+		  nnfolder-current-buffer nil))
+	  
+	  (setq nnfolder-current-group group)
+	  
+	  (when (or (not nnfolder-current-buffer)
+		    (not (verify-visited-file-modtime nnfolder-current-buffer)))
+	    (save-excursion
+	      (setq file (nnfolder-group-pathname group))
+	      ;; See whether we need to create the new file.
+	      (unless (file-exists-p file)
+		(gnus-make-directory (file-name-directory file))
+		(nnmail-write-region 1 1 file t 'nomesg))
+	      (when (setq nnfolder-current-buffer (nnfolder-read-folder group))
+		(set-buffer nnfolder-current-buffer)
+		(push (list group nnfolder-current-buffer)
+		      nnfolder-buffer-alist)))))))))
 
 (defun nnfolder-save-mail (group-art-list)
   "Called narrowed to an article."
@@ -751,6 +758,9 @@
 
 (defun nnfolder-group-pathname (group)
   "Make pathname for GROUP."
+  ;; 1997/8/14 by MORIOKA Tomohiko
+  ;;	encode file name for Emacs 20.
+  (setq group (encode-coding-string group nnmail-pathname-coding-system))
   (let ((dir (file-name-as-directory (expand-file-name nnfolder-directory))))
     ;; If this file exists, we use it directly.
     (if (or nnmail-use-long-file-names
diff -ruN --exclude=*~ --exclude=*.elc --exclude=*.orig xemacs/lisp/gnus/nnheader.el /usr/local/lib/xemacs/packages/lisp/gnus/nnheader.el
--- xemacs/lisp/gnus/nnheader.el	Mon Jul 21 05:34:48 1997
+++ /usr/local/lib/xemacs/packages/lisp/gnus/nnheader.el	Tue Aug 12 23:44:50 1997
@@ -667,6 +667,11 @@
   (or (not (numberp gnus-verbose-backends))
       (<= level gnus-verbose-backends)))
 
+;; 1997/8/10 by MORIOKA Tomohiko
+(defvar nnheader-pathname-coding-system
+  'iso-8859-1
+  "*Coding system for pathname.")
+
 (defun nnheader-group-pathname (group dir &optional file)
   "Make pathname for GROUP."
   (concat
@@ -675,7 +680,13 @@
      (if (file-directory-p (concat dir group))
 	 (concat dir group "/")
        ;; If not, we translate dots into slashes.
-       (concat dir (nnheader-replace-chars-in-string group ?. ?/) "/")))
+       (concat dir
+	       ;; 1997/8/10 by MORIOKA Tomohiko
+	       ;;	encode file name for Emacs 20.
+	       (encode-coding-string
+		(nnheader-replace-chars-in-string group ?. ?/)
+		nnheader-pathname-coding-system)
+	       "/")))
    (cond ((null file) "")
 	 ((numberp file) (int-to-string file))
 	 (t file))))
@@ -732,6 +743,10 @@
       (when (string-match (car ange-ftp-path-format) path)
 	(ange-ftp-re-read-dir path)))))
 
+;; 1997/5/4 by MORIOKA Tomohiko <morioka@jaist.ac.jp>
+(defvar nnheader-file-coding-system nil
+  "Coding system used in file backends of Gnus.")
+
 (defun nnheader-insert-file-contents (filename &optional visit beg end replace)
   "Like `insert-file-contents', q.v., but only reads in the file.
 A buffer may be modified in several ways after reading into the buffer due
@@ -741,7 +756,9 @@
   (let ((format-alist nil)
 	(auto-mode-alist (nnheader-auto-mode-alist))
 	(default-major-mode 'fundamental-mode)
-        (after-insert-file-functions nil))
+        (after-insert-file-functions nil)
+	;; 1997/5/4 by MORIOKA Tomohiko <morioka@jaist.ac.jp>
+	(coding-system-for-read nnheader-file-coding-system))
     (insert-file-contents filename visit beg end replace)))
 
 (defun nnheader-find-file-noselect (&rest args)
@@ -749,7 +766,9 @@
 	(auto-mode-alist (nnheader-auto-mode-alist))
 	(default-major-mode 'fundamental-mode)
 	(enable-local-variables nil)
-        (after-insert-file-functions nil))
+        (after-insert-file-functions nil)
+	;; 1997/5/16 by MORIOKA Tomohiko <morioka@jaist.ac.jp>
+	(coding-system-for-read nnheader-file-coding-system))
     (apply 'find-file-noselect args)))
 
 (defun nnheader-auto-mode-alist ()
diff -ruN --exclude=*~ --exclude=*.elc --exclude=*.orig xemacs/lisp/gnus/nnmail.el /usr/local/lib/xemacs/packages/lisp/gnus/nnmail.el
--- xemacs/lisp/gnus/nnmail.el	Mon Jul 21 05:34:48 1997
+++ /usr/local/lib/xemacs/packages/lisp/gnus/nnmail.el	Fri Aug 15 00:53:36 1997
@@ -473,6 +473,10 @@
 (defun nnmail-request-post (&optional server)
   (mail-send-and-exit nil))
 
+;; 1997/5/4 by MORIOKA Tomohiko <morioka@jaist.ac.jp>
+(defvar nnmail-file-coding-system nil
+  "Coding system used in nnmail.")
+
 (defun nnmail-find-file (file)
   "Insert FILE in server buffer safely."
   (set-buffer nntp-server-buffer)
@@ -480,9 +484,20 @@
   (let ((format-alist nil)
         (after-insert-file-functions nil))
     (condition-case ()
-	(progn (insert-file-contents file) t)
+	;; 1997/5/4 by MORIOKA Tomohiko <morioka@jaist.ac.jp>
+	(let ((coding-system-for-read nnmail-file-coding-system)
+	      ;; 1997/8/12 by MORIOKA Tomohiko
+	      ;;	for XEmacs/mule.
+	      (pathname-coding-system 'binary))
+	  (insert-file-contents file)
+	  t)
       (file-error nil))))
 
+;; 1997/8/10 by MORIOKA Tomohiko
+(defvar nnmail-pathname-coding-system
+  'iso-8859-1
+  "*Coding system for pathname.")
+
 (defun nnmail-group-pathname (group dir &optional file)
   "Make pathname for GROUP."
   (concat
@@ -492,7 +507,13 @@
 	     (file-directory-p (concat dir group)))
 	 (concat dir group "/")
        ;; If not, we translate dots into slashes.
-       (concat dir (nnheader-replace-chars-in-string group ?. ?/) "/")))
+       (concat dir
+	       ;; 1997/8/10 by MORIOKA Tomohiko
+	       ;;	encode file name for Emacs 20.
+	       (encode-coding-string
+		(nnheader-replace-chars-in-string group ?. ?/)
+		nnmail-pathname-coding-system)
+	       "/")))
    (or file "")))
 
 (defun nnmail-date-to-time (date)
@@ -670,11 +691,17 @@
 	      group-assoc)))
     group-assoc))
 
+;; 1997/8/12 by MORIOKA Tomohiko
+(defvar nnmail-active-file-coding-system
+  'iso-8859-1
+  "*Coding system for active file.")
+
 (defun nnmail-save-active (group-assoc file-name)
   "Save GROUP-ASSOC in ACTIVE-FILE."
-  (when file-name
-    (nnheader-temp-write file-name
-      (nnmail-generate-active group-assoc))))
+  (let ((coding-system-for-write nnmail-active-file-coding-system))
+    (when file-name
+      (nnheader-temp-write file-name
+	(nnmail-generate-active group-assoc)))))
 
 (defun nnmail-generate-active (alist)
   "Generate an active file from group-alist ALIST."
@@ -1127,7 +1154,12 @@
 		       (progn (forward-line 1) (point))))
       (insert (format "Xref: %s" (system-name)))
       (while group-alist
-	(insert (format " %s:%d" (caar group-alist) (cdar group-alist)))
+	;; 1997/8/10 by MORIOKA Tomohiko
+	;;	encode file name for Emacs 20.
+	(insert (format " %s:%d"
+			(encode-coding-string (caar group-alist)
+					      nnmail-pathname-coding-system)
+			(cdar group-alist)))
 	(setq group-alist (cdr group-alist)))
       (insert "\n"))))
 
@@ -1618,8 +1650,13 @@
 
 (defun nnmail-write-region (start end filename &optional append visit lockname)
   "Do a `write-region', and then set the file modes."
-  (write-region start end filename append visit lockname)
-  (set-file-modes filename nnmail-default-file-modes))
+  ;; 1997/5/4 by MORIOKA Tomohiko <morioka@jaist.ac.jp>
+  (let ((coding-system-for-write nnmail-file-coding-system)
+	;; 1997/8/12 by MORIOKA Tomohiko
+	;;	for XEmacs/mule.
+	(pathname-coding-system 'binary))
+    (write-region start end filename append visit lockname)
+    (set-file-modes filename nnmail-default-file-modes)))
 
 ;;;
 ;;; Status functions
diff -ruN --exclude=*~ --exclude=*.elc --exclude=*.orig xemacs/lisp/gnus/nnmh.el /usr/local/lib/xemacs/packages/lisp/gnus/nnmh.el
--- xemacs/lisp/gnus/nnmh.el	Mon Jul 21 05:34:48 1997
+++ /usr/local/lib/xemacs/packages/lisp/gnus/nnmh.el	Thu Aug 14 23:25:46 1997
@@ -76,6 +76,9 @@
 	   (large (and (numberp nnmail-large-newsgroup)
 		       (> number nnmail-large-newsgroup)))
 	   (count 0)
+	   ;; 1997/8/12 by MORIOKA Tomohiko
+	   ;;	for XEmacs/mule.
+	   (pathname-coding-system 'binary)
 	   beg article)
       (nnmh-possibly-change-directory newsgroup server)
       ;; We don't support fetching by Message-ID.
@@ -134,6 +137,9 @@
   (let ((file (if (stringp id)
 		  nil
 		(concat nnmh-current-directory (int-to-string id))))
+	;; 1997/8/12 by MORIOKA Tomohiko
+	;;	for XEmacs/mule.
+	(pathname-coding-system 'binary)
 	(nntp-server-buffer (or buffer nntp-server-buffer)))
     (and (stringp file)
 	 (file-exists-p file)
@@ -143,6 +149,9 @@
 
 (deffoo nnmh-request-group (group &optional server dont-check)
   (let ((pathname (nnmail-group-pathname group nnmh-directory))
+	;; 1997/8/12 by MORIOKA Tomohiko
+	;;	for XEmacs/mule.
+	(pathname-coding-system 'binary)
 	dir)
     (cond
      ((not (file-directory-p pathname))
@@ -181,7 +190,10 @@
 
 (deffoo nnmh-request-list (&optional server dir)
   (nnheader-insert "")
-  (let ((nnmh-toplev
+  (let (;; 1997/8/14 by MORIOKA Tomohiko
+	;;	for XEmacs/mule.
+	(pathname-coding-system 'binary)
+	(nnmh-toplev
 	 (file-truename (or dir (file-name-as-directory nnmh-directory)))))
     (nnmh-request-list-1 nnmh-toplev))
   (setq nnmh-group-alist (nnmail-get-active))
@@ -220,7 +232,9 @@
 				(expand-file-name nnmh-toplev))))
 	       dir)
 	      (nnheader-replace-chars-in-string
-	       (substring dir (match-end 0)) ?/ ?.))
+	       (decode-coding-string (substring dir (match-end 0))
+				     nnmail-pathname-coding-system)
+	       ?/ ?.))
 	    (apply 'max files)
 	    (apply 'min files)))))))
   t)
@@ -396,7 +410,10 @@
 	     (not (nnmh-server-opened server)))
     (nnmh-open-server server))
   (when newsgroup
-    (let ((pathname (nnmail-group-pathname newsgroup nnmh-directory)))
+    (let ((pathname (nnmail-group-pathname newsgroup nnmh-directory))
+	  ;; 1997/8/12 by MORIOKA Tomohiko
+	  ;;	for XEmacs/mule.
+	  (pathname-coding-system 'binary))
       (if (file-directory-p pathname)
 	  (setq nnmh-current-directory pathname)
 	(error "No such newsgroup: %s" newsgroup)))))
@@ -444,7 +461,10 @@
 (defun nnmh-active-number (group)
   "Compute the next article number in GROUP."
   (let ((active (cadr (assoc group nnmh-group-alist)))
-	(dir (nnmail-group-pathname group nnmh-directory)))
+	(dir (nnmail-group-pathname group nnmh-directory))
+	;; 1997/8/14 by MORIOKA Tomohiko
+	;;	for XEmacs/mule.
+	(pathname-coding-system 'binary))
     (unless active
       ;; The group wasn't known to nnmh, so we just create an active
       ;; entry for it.
diff -ruN --exclude=*~ --exclude=*.elc --exclude=*.orig xemacs/lisp/gnus/nnml.el /usr/local/lib/xemacs/packages/lisp/gnus/nnml.el
--- xemacs/lisp/gnus/nnml.el	Mon Jul 21 05:34:48 1997
+++ /usr/local/lib/xemacs/packages/lisp/gnus/nnml.el	Fri Aug 15 00:30:59 1997
@@ -98,6 +98,9 @@
       (let ((file nil)
 	    (number (length sequence))
 	    (count 0)
+	    ;; 1997/8/12 by MORIOKA Tomohiko
+	    ;;	for XEmacs/mule.
+	    (pathname-coding-system 'binary)
 	    beg article)
 	(if (stringp (car sequence))
 	    'headers
@@ -160,6 +163,9 @@
 (deffoo nnml-request-article (id &optional group server buffer)
   (nnml-possibly-change-directory group server)
   (let* ((nntp-server-buffer (or buffer nntp-server-buffer))
+	 ;; 1997/8/12 by MORIOKA Tomohiko
+	 ;;	for XEmacs/mule.
+	 (pathname-coding-system 'binary)
 	 path gpath group-num)
     (if (stringp id)
 	(when (and (setq group-num (nnml-find-group-number id))
@@ -188,27 +194,30 @@
 	    (string-to-int (file-name-nondirectory path)))))))
 
 (deffoo nnml-request-group (group &optional server dont-check)
-  (cond
-   ((not (nnml-possibly-change-directory group server))
-    (nnheader-report 'nnml "Invalid group (no such directory)"))
-   ((not (file-exists-p nnml-current-directory))
-    (nnheader-report 'nnml "Directory %s does not exist"
-		     nnml-current-directory))
-   ((not (file-directory-p nnml-current-directory))
-    (nnheader-report 'nnml "%s is not a directory" nnml-current-directory))
-   (dont-check
-    (nnheader-report 'nnml "Group %s selected" group)
-    t)
-   (t
-    (nnheader-re-read-dir nnml-current-directory)
-    (nnmail-activate 'nnml)
-    (let ((active (nth 1 (assoc group nnml-group-alist))))
-      (if (not active)
-	  (nnheader-report 'nnml "No such group: %s" group)
-	(nnheader-report 'nnml "Selected group %s" group)
-	(nnheader-insert "211 %d %d %d %s\n"
-			 (max (1+ (- (cdr active) (car active))) 0)
-			 (car active) (cdr active) group))))))
+  ;; 1997/8/12 by MORIOKA Tomohiko
+  ;;	for XEmacs/mule.
+  (let ((pathname-coding-system 'binary))
+    (cond
+     ((not (nnml-possibly-change-directory group server))
+      (nnheader-report 'nnml "Invalid group (no such directory)"))
+     ((not (file-exists-p nnml-current-directory))
+      (nnheader-report 'nnml "Directory %s does not exist"
+		       nnml-current-directory))
+     ((not (file-directory-p nnml-current-directory))
+      (nnheader-report 'nnml "%s is not a directory" nnml-current-directory))
+     (dont-check
+      (nnheader-report 'nnml "Group %s selected" group)
+      t)
+     (t
+      (nnheader-re-read-dir nnml-current-directory)
+      (nnmail-activate 'nnml)
+      (let ((active (nth 1 (assoc group nnml-group-alist))))
+	(if (not active)
+	    (nnheader-report 'nnml "No such group: %s" group)
+	  (nnheader-report 'nnml "Selected group %s" group)
+	  (nnheader-insert "211 %d %d %d %s\n"
+			   (max (1+ (- (cdr active) (car active))) 0)
+			   (car active) (cdr active) group)))))))
 
 (deffoo nnml-request-scan (&optional group server)
   (setq nnml-article-file-alist nil)
@@ -236,7 +245,12 @@
 
 (deffoo nnml-request-list (&optional server)
   (save-excursion
-    (nnmail-find-file nnml-active-file)
+    ;; 1997/8/12 by MORIOKA Tomohiko
+    ;;	for XEmacs/mule.
+    (let ((nnmail-file-coding-system nnmail-active-file-coding-system)
+	  (pathname-coding-system 'binary)) ; for XEmacs/mule
+      (nnmail-find-file nnml-active-file)
+      )
     (setq nnml-group-alist (nnmail-get-active))
     t))
 
@@ -547,7 +561,10 @@
     (nnml-open-server server))
   (if (not group)
       t
-    (let ((pathname (nnmail-group-pathname group nnml-directory)))
+    (let ((pathname (nnmail-group-pathname group nnml-directory))
+	  ;; 1997/8/14 by MORIOKA Tomohiko
+	  ;;	for XEmacs/mule.
+	  (pathname-coding-system 'binary))
       (when (not (equal pathname nnml-current-directory))
 	(setq nnml-current-directory pathname
 	      nnml-current-group group
diff -ruN --exclude=*~ --exclude=*.elc --exclude=*.orig xemacs/lisp/gnus/nnspool.el /usr/local/lib/xemacs/packages/lisp/gnus/nnspool.el
--- xemacs/lisp/gnus/nnspool.el	Mon Jul 21 05:34:48 1997
+++ /usr/local/lib/xemacs/packages/lisp/gnus/nnspool.el	Thu Aug 14 17:26:27 1997
@@ -82,6 +82,10 @@
 (defvoo nnspool-rejected-article-hook nil
   "*A hook that will be run when an article has been rejected by the server.")
 
+;; 1997/8/14 by MORIOKA Tomohiko
+(defvoo nnspool-file-coding-system nnheader-file-coding-system
+  "Coding system for nnspool.")
+
 
 
 (defconst nnspool-version "nnspool 2.0"
@@ -109,6 +113,9 @@
 	     (default-directory nnspool-current-directory)
 	     (do-message (and (numberp nnspool-large-newsgroup)
 			      (> number nnspool-large-newsgroup)))
+	     ;; 1997/8/14 by MORIOKA Tomohiko
+	     ;;   for Win32
+	     (nnheader-file-coding-system nnspool-file-coding-system)
 	     file beg article ag)
 	(if (and (numberp (car articles))
 		 (nnspool-retrieve-headers-with-nov articles fetch-old))
@@ -349,6 +356,9 @@
     (let ((nov (nnheader-group-pathname
 		nnspool-current-group nnspool-nov-directory ".overview"))
 	  (arts articles)
+	  ;; 1997/8/14 by MORIOKA Tomohiko
+	  ;;   for Win32
+      	  (nnheader-file-coding-system nnspool-file-coding-system)
 	  last)
       (if (not (file-exists-p nov))
 	  ()
@@ -430,7 +440,11 @@
   (set-buffer nntp-server-buffer)
   (erase-buffer)
   (condition-case ()
-      (progn (nnheader-insert-file-contents file) t)
+      ;; 1997/8/14 by MORIOKA Tomohiko
+      ;;   for Win32
+      (let ((nnheader-file-coding-system nnspool-file-coding-system))
+	(nnheader-insert-file-contents file)
+	t)
     (file-error nil)))
 
 (defun nnspool-possibly-change-directory (group)
diff -ruN --exclude=*~ --exclude=*.elc --exclude=*.orig xemacs/lisp/gnus/nntp.el /usr/local/lib/xemacs/packages/lisp/gnus/nntp.el
--- xemacs/lisp/gnus/nntp.el	Mon Jul 21 05:34:48 1997
+++ /usr/local/lib/xemacs/packages/lisp/gnus/nntp.el	Sat Aug  2 01:18:52 1997
@@ -149,6 +149,10 @@
 (defvoo nntp-warn-about-losing-connection t
   "*If non-nil, beep when a server closes connection.")
 
+;; 1997/5/4 by MORIOKA Tomohiko <morioka@jaist.ac.jp>
+(defvoo nntp-coding-system-for-read nil
+  "*coding-system for read from NNTP.")
+
 
 
 ;;; Internal variables.
@@ -745,7 +749,9 @@
   (let* ((pbuffer (nntp-make-process-buffer buffer))
 	 (process
 	  (condition-case ()
-	      (funcall nntp-open-connection-function pbuffer)
+	      ;; 1997/5/4 by MORIOKA Tomohiko <morioka@jaist.ac.jp>
+	      (let ((coding-system-for-read nntp-coding-system-for-read))
+		(funcall nntp-open-connection-function pbuffer))
 	    (error nil)
 	    (quit nil))))
     (when process
diff -ruN --exclude=*~ --exclude=*.elc --exclude=*.orig xemacs/lisp/gnus/pop3.el /usr/local/lib/xemacs/packages/lisp/gnus/pop3.el
--- xemacs/lisp/gnus/pop3.el	Mon Jul 21 05:34:48 1997
+++ /usr/local/lib/xemacs/packages/lisp/gnus/pop3.el	Thu Aug 14 16:18:40 1997
@@ -60,6 +60,9 @@
   "Timestamp returned when initially connected to the POP server.
 Used for APOP authentication.")
 
+(defvar pop3-movemail-file-coding-system nil
+  "Crashbox made by pop3-movemail with this coding system.")
+
 (defvar pop3-read-point nil)
 (defvar pop3-debug nil)
 
@@ -85,7 +88,8 @@
       (pop3-retr process n crashbuf)
       (save-excursion
 	(set-buffer crashbuf)
-	(append-to-file (point-min) (point-max) crashbox)
+	(let ((coding-system-for-write pop3-movemail-file-coding-system))
+	  (append-to-file (point-min) (point-max) crashbox))
 	(set-buffer (process-buffer process))
 	(while (> (buffer-size) 5000)
 	  (goto-char (point-min))
