switch ${%foo} to wcswidth-like behaviour – slightly problematic, and

the “set +U” case isn’t even handled

committed to branch because I’d like to get more input on this, for now
This commit is contained in:
tg
2009-11-28 14:21:47 +00:00
parent 7063a9a921
commit 883d9d99b3
9 changed files with 37 additions and 21 deletions

View File

@ -25,7 +25,7 @@
#include "sh.h"
__RCSID("$MirOS: src/bin/mksh/funcs.c,v 1.142 2009/11/09 23:35:09 tg Exp $");
__RCSID("$MirOS: src/bin/mksh/funcs.c,v 1.143 2009/11/28 14:21:44 tg Exp $");
#if HAVE_KILLPG
/*
@ -1551,7 +1551,7 @@ c_kill(const char **wp)
w = strlen(sigtraps[j].mess);
if (w > mess_octs)
mess_octs = w;
w = utf_mbswidth(sigtraps[j].mess);
w = utf_mbswidth(sigtraps[j].mess, true);
if (w > mess_cols)
mess_cols = w;
}