diff options
author | Andrew Tridgell <tridge@samba.org> | 2009-08-12 14:38:55 +1000 |
---|---|---|
committer | Andrew Tridgell <tridge@samba.org> | 2009-08-12 14:38:55 +1000 |
commit | 0ae3912f328250703e921ec78eb9add98cbfcf7c (patch) | |
tree | 5c84f03ad809fc12d4aca5d386454c46499a8143 /selftest/target | |
parent | 7bc566a88277ecbc0f712b7c54116163930f187d (diff) | |
download | samba-0ae3912f328250703e921ec78eb9add98cbfcf7c.tar.gz samba-0ae3912f328250703e921ec78eb9add98cbfcf7c.tar.bz2 samba-0ae3912f328250703e921ec78eb9add98cbfcf7c.zip |
print server log on stderr as well as to log file
I think we are missing some important messages from the server during
'make test' because we don't show the log file contents during
runs. This patch uses tee to put the log messages to stderr so we can
see any server messages associated with the test that caused them.
Diffstat (limited to 'selftest/target')
-rw-r--r-- | selftest/target/Samba4.pm | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/selftest/target/Samba4.pm b/selftest/target/Samba4.pm index 0f909ce4b2..81ad09dbc0 100644 --- a/selftest/target/Samba4.pm +++ b/selftest/target/Samba4.pm @@ -88,9 +88,12 @@ sub check_or_start($$$) my $pid = fork(); if ($pid == 0) { open STDIN, $env_vars->{SAMBA_TEST_FIFO}; - open STDOUT, ">$env_vars->{SAMBA_TEST_LOG}"; + # we want out from samba to go to the log file, but also + # to the users terminal when running 'make test' on the command + # line. This puts it on stderr on the terminal + open STDOUT, "| tee $env_vars->{SAMBA_TEST_LOG} 1>&2"; open STDERR, '>&STDOUT'; - + SocketWrapper::set_default_iface($env_vars->{SOCKET_WRAPPER_DEFAULT_IFACE}); my $valgrind = ""; |