X-Git-Url: https://git.distorted.org.uk/~mdw/sgt/putty/blobdiff_plain/a5f3e637bc3925f7c68ab0f3895408bb70154b13..66ee282adab99e6ef6ab7e09700611c89d87c97c:/ldisc.c diff --git a/ldisc.c b/ldisc.c index b307d4e1..e1b5a389 100644 --- a/ldisc.c +++ b/ldisc.c @@ -28,7 +28,7 @@ static int term_buflen = 0, term_bufsiz = 0, term_quotenext = 0; static int plen(unsigned char c) { - if ((c >= 32 && c <= 126) || (c >= 160)) + if ((c >= 32 && c <= 126) || (c >= 160 && !in_utf)) return 1; else if (c < 128) return 2; /* ^x for some x */ @@ -38,7 +38,7 @@ static int plen(unsigned char c) static void pwrite(unsigned char c) { - if ((c >= 32 && c <= 126) || (c >= 160)) { + if ((c >= 32 && c <= 126) || (c >= 160 && !in_utf)) { c_write(&c, 1); } else if (c < 128) { char cc[2];