summaryrefslogtreecommitdiff
path: root/strings
diff options
context:
space:
mode:
authorbar@mysql.com <>2006-04-11 18:16:14 +0500
committerbar@mysql.com <>2006-04-11 18:16:14 +0500
commite8e0d5c5fefa34b6d1aa10befc82564ae60a939b (patch)
tree1d0a5e974ab559eef30edb0da17607e8dc870d0f /strings
parent58ad55937d43682a5ea9780ca68fca06fb9571de (diff)
downloadmariadb-git-e8e0d5c5fefa34b6d1aa10befc82564ae60a939b.tar.gz
bug#17870 Table names conflict with Windows device names
It was impossible to create some table names on Windows (e.g. LPT1, AUX, COM1, etc). Fixed to pad dangerous names with thee "at" signs (e.g. LPT1@@@, AUX@@@, COM1@@@, and so on).
Diffstat (limited to 'strings')
-rw-r--r--strings/ctype-utf8.c5
1 files changed, 5 insertions, 0 deletions
diff --git a/strings/ctype-utf8.c b/strings/ctype-utf8.c
index e3bba3ee1e3..1a952a07042 100644
--- a/strings/ctype-utf8.c
+++ b/strings/ctype-utf8.c
@@ -3943,6 +3943,11 @@ my_mb_wc_filename(CHARSET_INFO *cs __attribute__((unused)),
*pwc= touni[code];
return 3;
}
+ if (byte1 == '@' && byte2 == '@')
+ {
+ *pwc= 0;
+ return 3;
+ }
}
if (s + 4 > e)