help-gnu-emacs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Very basic question regarding encoding and `open-network-stream'


From: Eric Abrahamsen
Subject: Re: Very basic question regarding encoding and `open-network-stream'
Date: Tue, 27 Nov 2018 15:41:09 -0800
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/27.0.50 (gnu/linux)

Stefan Monnier <monnier@iro.umontreal.ca> writes:

>> The NNTP RFC notes that the default character set for the protocol has
>> changed from ascii to utf-8.
>> (https://tools.ietf.org/html/rfc3977#section-1)
>>
>> What I don't grasp is: if the process buffers are left multibyte, and
>> the `coding-system-for-read/write' variables are changed to 'utf-8 (or
>> 'undecided?), will this simply do the right thing?
>
> No: the stream of bytes includes NNTP protocol commands as well as other
> contents (typically actual messages) and they don't all use utf-8.
> So the stream process needs to communicate in bytes (aka "unibyte"), and
> then the Elisp code needs to decode/encode each part manually according
> to the coding system that applies to each part.

Awesome, this will save me wandering down some garden paths, thank you.
I will make the Minimum Viable Changes, and just focus on group names.




reply via email to

[Prev in Thread] Current Thread [Next in Thread]