Fix bug #60933 (Testing asort with SORT_LOCALE_STRING fails on Mac OS X 10.6) on PHP_5_3 and trunk.

This commit is contained in:
Adam Harvey 2012-02-03 01:21:24 +00:00
parent f906a015bb
commit 325ca60fa7

View File

@ -5,7 +5,7 @@ Sort with SORT_LOCALE_STRING
if (substr(PHP_OS, 0, 3) == 'WIN') { if (substr(PHP_OS, 0, 3) == 'WIN') {
die("skip Unix locale name only, not available on windows (and crashes with VC6)\n"); die("skip Unix locale name only, not available on windows (and crashes with VC6)\n");
} }
if (false == setlocale(LC_CTYPE, "fr_FR", "fr_FR.ISO8859-1")) { if (false == setlocale(LC_CTYPE, "fr_FR.ISO8859-1", "fr_FR")) {
die("skip setlocale() failed\n"); die("skip setlocale() failed\n");
} }
?> ?>
@ -14,7 +14,7 @@ unicode.script_encoding=ISO8859-1
unicode.output_encoding=ISO8859-1 unicode.output_encoding=ISO8859-1
--FILE-- --FILE--
<?php <?php
setlocale(LC_ALL, 'fr_FR', 'fr_FR.ISO8859-1'); setlocale(LC_ALL, 'fr_FR.ISO8859-1', 'fr_FR');
$table = array("AB" => "Alberta", $table = array("AB" => "Alberta",
"BC" => "Colombie-Britannique", "BC" => "Colombie-Britannique",
"MB" => "Manitoba", "MB" => "Manitoba",