Subject that ends with UTF-8, 85 or A0 e.g.:

Kevin J. McCarthy kevin at 8t8.us
Wed Aug 3 02:42:14 UTC 2022


On Wed, Aug 03, 2022 at 09:53:42AM +0900, Kenichi Asai wrote:
>> * In the step:
>>   "- enter some e-mail address and a subject."
>> if instead, you put a 加 at the end of the subject here, before running vim,
>> does 加 show up in vim?
>
>Yes.
>
>> If you then don't modify the subject while still in
>> vim, does it show up in Mutt?
>
>No.  It becomes the replacement character.

Thank you for taking the time to answer all my questions.

The subject line you sent appears to be truncated by one byte.  This 
also occurred for the 加 emails earlier.

Would you mind creating a script to use for $editor.  Something like:

- - - - myeditor.sh - - - -
   #!/bin/bash

   cp $1 ~/before.txt
   vim $1
   cp $1 ~/after.txt
- - - - end myeditor.sh - - -

set editor = "~/myeditor.sh"

Then, if you put 加 at the end of the subject while in Mutt.  I'd like 
to see what before.txt and after.txt look like after vim runs.  Please 
attach them so I can look at the raw bytes.

Also, if you have access to a compiler, would you mind compiling and 
running this quick program:

- - - - test.c - - - -
#include <stdio.h>
#include <ctype.h>

int main ()
{
   printf("%d\n", isspace(0xa0));
   printf("%d\n", isspace(0x85));
   printf("%d\n", isspace(0x0a));

   return 0;
}
- - - - end test.c - - - -

% gcc -o test test.c
% ./test

Thank you again.

-- 
Kevin J. McCarthy
GPG Fingerprint: 8975 A9B3 3AA3 7910 385C  5308 ADEF 7684 8031 6BDA
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 833 bytes
Desc: not available
URL: <http://lists.mutt.org/pipermail/mutt-users/attachments/20220802/c9865845/attachment.asc>


More information about the Mutt-users mailing list