diff -r f98cb867cc0e -r f34432aa0233 console/libgnt/gntutils.c --- a/console/libgnt/gntutils.c Thu Oct 12 03:30:25 2006 +0000 +++ b/console/libgnt/gntutils.c Thu Oct 12 03:33:07 2006 +0000 @@ -59,6 +59,10 @@ int width = 0; const char *str = string; + if (len <= 0) { + len = g_utf8_strlen(string, -1); + } + while (width < len && *str) { size = g_unichar_iswide(g_utf8_get_char(str)) ? 2 : 1; if (width + size > len)