diff options
author | unknown <knielsen@knielsen-hq.org> | 2010-04-29 09:29:04 +0200 |
---|---|---|
committer | unknown <knielsen@knielsen-hq.org> | 2010-04-29 09:29:04 +0200 |
commit | 5a0af835ccaef1125478a2895b1ce5bc12626759 (patch) | |
tree | a60bad80f3a68adedf93519708e43633033927ed /strings | |
parent | 1f683a7270e63abfadce20c6f51370621ff065e1 (diff) | |
download | mariadb-git-5a0af835ccaef1125478a2895b1ce5bc12626759.tar.gz |
Fix missing bounds check in string conversion.
Bump version number for security fix release.
Diffstat (limited to 'strings')
-rw-r--r-- | strings/ctype-utf8.c | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/strings/ctype-utf8.c b/strings/ctype-utf8.c index f99c34ec39a..9cfee43fa36 100644 --- a/strings/ctype-utf8.c +++ b/strings/ctype-utf8.c @@ -4116,6 +4116,10 @@ my_wc_mb_filename(CHARSET_INFO *cs __attribute__((unused)), { int code; char hex[]= "0123456789abcdef"; + + if (s >= e) + return MY_CS_TOOSMALL; + if (wc < 128 && filename_safe_char[wc]) { *s= (uchar) wc; |