Fixes Savannah bug #35764.
2012-09-09 Paul Smith <psmith@gnu.org>
+ * scripts/functions/file: Get errors in the C locale, not the
+ current locale. Fixes Savannah bug #35764.
+
* scripts/features/escape: Check that backslashes before
non-special characters are not removed.
chmod(0444, 'file.out');
# Find the error that will be printed
+# This seems complicated, but we need the message from the C locale
+my $loc = undef;
+if ($has_POSIX) {
+ $loc = POSIX::setlocale(POSIX::LC_MESSAGES);
+ POSIX::setlocale(POSIX::LC_MESSAGES, 'C');
+}
my $e;
open(my $F, '>', 'file.out') and die "Opened read-only file!\n";
$e = "$!";
+$loc and POSIX::setlocale(POSIX::LC_MESSAGES, $loc);
run_make_test(q!
define A