diff options
-rw-r--r-- | center.c | 4 |
1 files changed, 2 insertions, 2 deletions
@@ -230,8 +230,8 @@ utf8len(const char *s) { int l = 0; - while (*s) - l += (*s++ & 0xC0) != 0x80; + for (; *s; s++) + l += *s == '\b' ? -1 : (*s & 0xC0) != 0x80; if (l > 0 && s[-1] == '\n') l--; |