aboutsummaryrefslogtreecommitdiff
path: root/common/unicode.c
diff options
context:
space:
mode:
authorDrew DeVault <sir@cmpwn.com>2018-07-23 20:27:56 -0400
committerDrew DeVault <sir@cmpwn.com>2018-07-23 20:31:11 -0400
commitf4b882475eee7a81c206c7825616cc4656b2f60b (patch)
tree38e6ebf81b235424f105dcbcbb194e5e9eac70c0 /common/unicode.c
parentacd79e1505c06089e4fb9fb6c0c6e1d351ba9176 (diff)
parent224ade138208e9aa525423cbfbd643aa9d9b63c3 (diff)
Merge branch 'master' into pid-workspaces
Diffstat (limited to 'common/unicode.c')
-rw-r--r--common/unicode.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/common/unicode.c b/common/unicode.c
index 38a9b48e..5070e083 100644
--- a/common/unicode.c
+++ b/common/unicode.c
@@ -92,7 +92,7 @@ static const struct {
int utf8_size(const char *s) {
uint8_t c = (uint8_t)*s;
- for (size_t i = 0; i < sizeof(sizes) / 2; ++i) {
+ for (size_t i = 0; i < sizeof(sizes) / sizeof(*sizes); ++i) {
if ((c & sizes[i].mask) == sizes[i].result) {
return sizes[i].octets;
}