From 5a0af835ccaef1125478a2895b1ce5bc12626759 Mon Sep 17 00:00:00 2001 From: unknown Date: Thu, 29 Apr 2010 09:29:04 +0200 Subject: Fix missing bounds check in string conversion. Bump version number for security fix release. --- strings/ctype-utf8.c | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'strings') 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; -- cgit v1.2.1