diff options
author | Russ Cox <russcox@gmail.com> | 2009-09-11 17:03:06 -0400 |
---|---|---|
committer | Russ Cox <russcox@gmail.com> | 2009-09-11 17:03:06 -0400 |
commit | 0cadb4301d18724e7513d7489cb5bebd262c82f1 (patch) | |
tree | 48209a4083885288eaa09178d4017769897107b3 /src/cmd/troff | |
parent | 4dbf255619efac4f0a00e4216d6c999128910df2 (diff) | |
download | plan9port-0cadb4301d18724e7513d7489cb5bebd262c82f1.tar.gz plan9port-0cadb4301d18724e7513d7489cb5bebd262c82f1.tar.bz2 plan9port-0cadb4301d18724e7513d7489cb5bebd262c82f1.zip |
convert to 4-byte UTF-8 and 32-bit Rune
http://codereview.appspot.com/116075
Diffstat (limited to 'src/cmd/troff')
-rw-r--r-- | src/cmd/troff/mbwc.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/cmd/troff/mbwc.c b/src/cmd/troff/mbwc.c index e5234896..c97b036c 100644 --- a/src/cmd/troff/mbwc.c +++ b/src/cmd/troff/mbwc.c @@ -152,9 +152,9 @@ wcstombs(char *s, const wchar_t *pwcs, size_t n) if(p+d <= pe+3) { *p++ = buf[0]; if(d > 1) { - *p++ = buf[2]; + *p++ = buf[1]; if(d > 2) - *p++ = buf[3]; + *p++ = buf[2]; } } if(c == 0) |