aboutsummaryrefslogtreecommitdiffstats
path: root/lib/Iurt/Util.pm
diff options
context:
space:
mode:
Diffstat (limited to 'lib/Iurt/Util.pm')
-rw-r--r--lib/Iurt/Util.pm4
1 files changed, 2 insertions, 2 deletions
diff --git a/lib/Iurt/Util.pm b/lib/Iurt/Util.pm
index a101f76..68f3fba 100644
--- a/lib/Iurt/Util.pm
+++ b/lib/Iurt/Util.pm
@@ -68,10 +68,10 @@ my %plog_level = (
sub plog_init {
$plog_name = shift;
$plog_file = shift;
- $plog_level = shift @_ || 9999;
+ $plog_level = shift @_;
$plog_color = shift @_ || 0;
- $plog_level = 9999 if $ENV{PLOG_DEBUG};
+ $plog_level = 9999 if ($ENV{PLOG_DEBUG} || ! ($plog_level >= 0));
$plog_color = 0 unless -t fileno $plog_file;