display: check the correct character for being double-width

This fixes https://savannah.gnu.org/bugs/?50741.
master
Benno Schulenberg 2017-04-06 17:31:36 +02:00
parent de0adb8e3e
commit 6ec65d5500
1 changed files with 1 additions and 1 deletions

View File

@ -1932,7 +1932,7 @@ char *display_string(const char *buf, size_t start_col, size_t span,
#ifdef ENABLE_UTF8
/* Display the left half of a two-column character as '>'. */
if (using_utf8() && mbwidth(buf) == 2)
if (mbwidth(converted + index) == 2)
converted[index++] = '>';
#endif
}