summaryrefslogtreecommitdiff
path: root/strings
diff options
context:
space:
mode:
Diffstat (limited to 'strings')
-rw-r--r--strings/ctype-utf8.c2
-rw-r--r--strings/decimal.c1
2 files changed, 2 insertions, 1 deletions
diff --git a/strings/ctype-utf8.c b/strings/ctype-utf8.c
index 3c2c812a004..c0865157ad5 100644
--- a/strings/ctype-utf8.c
+++ b/strings/ctype-utf8.c
@@ -7025,7 +7025,7 @@ my_wc_mb_filename(CHARSET_INFO *cs __attribute__((unused)),
}
/* Non letter */
- if (s + 5 > e)
+ if (s + 4 > e)
return MY_CS_TOOSMALL5;
*s++= hex[(wc >> 12) & 15];
diff --git a/strings/decimal.c b/strings/decimal.c
index da47727bd9c..2353a8aefce 100644
--- a/strings/decimal.c
+++ b/strings/decimal.c
@@ -383,6 +383,7 @@ int decimal2string(const decimal_t *from, char *to, int *to_len,
}
else
frac-=j;
+ frac_len= frac;
len= from->sign + intg_len + MY_TEST(frac) + frac_len;
}
*to_len=len;