Skip to content

Commit feb1f86

Browse files
committed
Fixed typo
1 parent 0155e45 commit feb1f86

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

lib/ExtUtils/MakeMaker.pm

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -220,12 +220,12 @@ sub prompt ($;$) { ## no critic
220220
if ($Is_Win32) {
221221
require Win32::Console;
222222
require Encode;
223-
my $codepage = Win32::GetConsoleCP(); # get the input code page
223+
$codepage = Win32::GetConsoleCP(); # get the input code page
224224
}
225225
$ans = <STDIN>;
226226
if( defined $ans ) {
227227
$ans =~ s{\015?\012$}{};
228-
if ($Is_Win32) {
228+
if ($Is_Win32 and defined $codepage) {
229229
$ans = Encode::decode("cp". $codepage, $ans);
230230
}
231231
}

0 commit comments

Comments
 (0)