vty_mk_wcwidth: simplify check

This commit is contained in:
Jonathan Daugherty 2020-03-05 14:18:30 -08:00
parent ee91cb6245
commit 1dc1239b39

View File

@ -233,7 +233,7 @@ static HsInt builtin_wcwidth(HsChar ucs)
// present, the built-in width table will be used.
HsInt vty_mk_wcwidth(HsChar ch)
{
if (custom_table != NULL) {
if (custom_table_ready) {
if ((ch >= 0) && (ch < custom_table_size)) {
return custom_table[ch];
} else {