[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Emacs-diffs] scratch/gnus-decoded 3460502: Decode Gnus group names when
From: |
Eric Abrahamsen |
Subject: |
[Emacs-diffs] scratch/gnus-decoded 3460502: Decode Gnus group names when browsing server group lists |
Date: |
Tue, 23 Apr 2019 23:34:17 -0400 (EDT) |
branch: scratch/gnus-decoded
commit 3460502128ab6ac4b68d9b5dce5d1602547e7d67
Author: Eric Abrahamsen <address@hidden>
Commit: Eric Abrahamsen <address@hidden>
Decode Gnus group names when browsing server group lists
* lisp/gnus/gnus-srvr.el (gnus-browse-foreign-server): The coding
system for the nntp-server-buffer is 'binary; decode group names as
'utf-8-emacs.
---
lisp/gnus/gnus-srvr.el | 38 +++++++++++++++++++++-----------------
1 file changed, 21 insertions(+), 17 deletions(-)
diff --git a/lisp/gnus/gnus-srvr.el b/lisp/gnus/gnus-srvr.el
index 2328f1d..da110c8 100644
--- a/lisp/gnus/gnus-srvr.el
+++ b/lisp/gnus/gnus-srvr.el
@@ -784,11 +784,13 @@ claim them."
(while (not (eobp))
(ignore-errors
(push (cons
- (buffer-substring
- (point)
- (progn
- (skip-chars-forward "^ \t")
- (point)))
+ (decode-coding-string
+ (buffer-substring
+ (point)
+ (progn
+ (skip-chars-forward "^ \t")
+ (point)))
+ 'utf-8-emacs)
(let ((last (read cur)))
(cons (read cur) last)))
groups))
@@ -796,18 +798,20 @@ claim them."
(while (not (eobp))
(ignore-errors
(push (cons
- (if (eq (char-after) ?\")
- (read cur)
- (let ((p (point)) (name ""))
- (skip-chars-forward "^ \t\\\\")
- (setq name (buffer-substring p (point)))
- (while (eq (char-after) ?\\)
- (setq p (1+ (point)))
- (forward-char 2)
- (skip-chars-forward "^ \t\\\\")
- (setq name (concat name (buffer-substring
- p (point)))))
- name))
+ (decode-coding-string
+ (if (eq (char-after) ?\")
+ (read cur)
+ (let ((p (point)) (name ""))
+ (skip-chars-forward "^ \t\\\\")
+ (setq name (buffer-substring p (point)))
+ (while (eq (char-after) ?\\)
+ (setq p (1+ (point)))
+ (forward-char 2)
+ (skip-chars-forward "^ \t\\\\")
+ (setq name (concat name (buffer-substring
+ p (point)))))
+ name))
+ 'utf-8-emacs)
(let ((last (read cur)))
(cons (read cur) last)))
groups))
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [Emacs-diffs] scratch/gnus-decoded 3460502: Decode Gnus group names when browsing server group lists,
Eric Abrahamsen <=