Author: kwilliams
Date: Thu Mar  1 04:35:28 2007
New Revision: 9182

Modified:
   Module-Build/trunk/Changes
   Module-Build/trunk/lib/Module/Build/Base.pm

Log:
Fix a hang in prompt()

Modified: Module-Build/trunk/Changes
==============================================================================
--- Module-Build/trunk/Changes  (original)
+++ Module-Build/trunk/Changes  Thu Mar  1 04:35:28 2007
@@ -1,5 +1,8 @@
 Revision history for Perl extension Module::Build.
 
+ - Improved our prompt() method, which could sometimes hang before the
+   user got a chance to see a prompt. [Andreas Koenig]
+
  - Added DragonflyBSD to the list of known Unix OSes.
 
  - get_action_docs() dies on error rather than twiddling $@

Modified: Module-Build/trunk/lib/Module/Build/Base.pm
==============================================================================
--- Module-Build/trunk/lib/Module/Build/Base.pm (original)
+++ Module-Build/trunk/lib/Module/Build/Base.pm Thu Mar  1 04:35:28 2007
@@ -471,7 +471,8 @@
 
 sub _is_unattended {
   my $self = shift;
-  return $ENV{PERL_MM_USE_DEFAULT} || ( !$self->_is_interactive && eof STDIN );
+  return $ENV{PERL_MM_USE_DEFAULT}
+         || ( !$self->_is_interactive && !defined fileno STDIN );
 }
 
 sub _readline {

Reply via email to