put dx.pl into an explicit handle sub
[spider.git] / perl / DXLogPrint.pm
index 356c7cd1efb3dd44c9904dd587a35aaa9087e5bd..b16d69e4c055b38406c7a52c30972acea6f2900f 100644 (file)
@@ -3,7 +3,7 @@
 #
 # Copyright (c) - 1998 Dirk Koopman G1TLH
 #
-# $Id$
+#
 #
 
 package DXLog;
@@ -18,12 +18,7 @@ use RingBuf;
 
 use strict;
 
-use vars qw($VERSION $BRANCH $maxmonths);
-$VERSION = sprintf( "%d.%03d", q$Revision$ =~ /(\d+)\.(\d+)/ );
-$BRANCH = sprintf( "%d.%03d", q$Revision$ =~ /\d+\.\d+\.(\d+)\.(\d+)/  || (0,0));
-$main::build += $VERSION;
-$main::branch += $BRANCH;
-
+use vars qw($maxmonths);
 $maxmonths = 36;
 
 #
@@ -38,7 +33,7 @@ sub print
        my $to = shift || 10;
        my $jdate = $fcb->unixtoj(shift);
        my $pattern = shift;
-       my $who = uc shift;
+       my $who = shift;
        my $search;
        my @in;
        my @out = ();
@@ -46,6 +41,8 @@ sub print
        my $tot = $from + $to;
        my $hint = "";
            
+       $who = uc $who if defined $who;
+       
        if ($pattern) {
                $hint = "m{\\Q$pattern\\E}i";
        } else {