From a53b80b3f3f187370d3360202b7849856ab9582a Mon Sep 17 00:00:00 2001 From: unknown Date: Wed, 23 May 2007 17:32:40 +0500 Subject: [PATCH] Bug#27636 mysqlbinlog-cp932 and ctype_cp932 tests fails if LC_* variables set to *_*.UTF-8 As MySQL character set tests can print results in many character sets (latin1, utf8-8, sjis, cp932 and others) - its output can be incompatible with the current locale settings, which makes PERL confuse. Fix: reset LC_ALL and LC_CTYPE to "C", which is compatible with any character set. mysql-test/mysql-test-run.pl: Ignore current locale settings, because "mysqltest" output can be not compatible with the locale. --- mysql-test/mysql-test-run.pl | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/mysql-test/mysql-test-run.pl b/mysql-test/mysql-test-run.pl index b48ac6c5abc..cbd7ccd5bbd 100755 --- a/mysql-test/mysql-test-run.pl +++ b/mysql-test/mysql-test-run.pl @@ -1792,6 +1792,18 @@ sub environment_setup () { $ENV{'CHARSETSDIR'}= $path_charsetsdir; $ENV{'UMASK'}= "0660"; # The octal *string* $ENV{'UMASK_DIR'}= "0770"; # The octal *string* + + # + # MySQL tests can produce output in various character sets + # (especially, ctype_xxx.test). To avoid confusing Perl + # with output which is incompatible with the current locale + # settings, we reset the current values of LC_ALL and LC_CTYPE to "C". + # For details, please see + # Bug#27636 tests fails if LC_* variables set to *_*.UTF-8 + # + $ENV{'LC_ALL'}= "C"; + $ENV{'LC_CTYPE'}= "C"; + $ENV{'LC_COLLATE'}= "C"; $ENV{'USE_RUNNING_SERVER'}= $opt_extern; $ENV{'MYSQL_TEST_DIR'}= $glob_mysql_test_dir;