Hi Fran���ois,
---
���testbot/lib/WineTestBot/Log.pm | ��� 16 +++++++---------
���1 file changed, 7 insertions(+), 9 deletions(-)
diff --git a/testbot/lib/WineTestBot/Log.pm b/testbot/lib/WineTestBot/Log.pm
index 6883968..7de6dcb 100644
--- a/testbot/lib/WineTestBot/Log.pm
+++ b/testbot/lib/WineTestBot/Log.pm
@@ -38,20 +38,18 @@ sub LogMsg(@)
��� ���if (!defined $logfile)
��� ���{
��� ��� ���my $oldumask = umask(002);
- ��� ���if (open($logfile, ">>", "$LogDir/log"))
- ��� ���{
- ��� ��� ���# Flush after each print
- ��� ��� ���my $tmp=select($logfile);
- ��� ��� ���$| = 1;
- ��� ��� ���select($tmp);
- ��� ���}
- ��� ���else
+ ��� ���if (!open($logfile, ">>", "$LogDir/log"))
��� ��� ���{
��� ��� ��� ���require File::Basename;
��� ��� ��� ���print STDERR File::Basename::basename($0), ":warning: could not open '$LogDir/log' for writing: $!\n";
- ��� ��� ���$logfile = undef;
+ ��� ��� ���open($logfile, ">>&=", 2);
��� ��� ���}
��� ��� ���umask($oldumask);
+
+ ��� ���# Flush after each print
+ ��� ���my $tmp=select($logfile);
+ ��� ���$| = 1;
+ ��� ���select($tmp);
��� ���}
��� ���print $logfile scalar localtime, " ", @_ if ($logfile);
���}
--
1.7.10.4