summaryrefslogtreecommitdiffstats
path: root/urpm/msg.pm
diff options
context:
space:
mode:
Diffstat (limited to 'urpm/msg.pm')
-rw-r--r--urpm/msg.pm7
1 files changed, 4 insertions, 3 deletions
diff --git a/urpm/msg.pm b/urpm/msg.pm
index 75b65a27..18053e13 100644
--- a/urpm/msg.pm
+++ b/urpm/msg.pm
@@ -46,10 +46,11 @@ sub N {
my $noexpr = N("Nn");
my $yesexpr = N("Yy");
+#- writes only to logfile, not to screen
sub log_it {
- #- if invoked as a simple user, nothing should be logged.
- if ($::log) {
- open my $fh, ">>$::log" or die "can't output to log file: $!\n";
+ if ($::logfile) {
+ open my $fh, ">>$::logfile"
+ or die "Can't output to log file [$::logfile]: $!\n";
print $fh @_;
close $fh;
}