X-Git-Url: http://dxcluster.org/gitweb/gitweb.cgi?a=blobdiff_plain;f=perl%2FDXUtil.pm;h=994cdd981a735c4753aeedbedac8c46d08b1ea82;hb=fb554d0fdb1d30120dbfff15514c51f683dc17a8;hp=81bace8ca1271ebc45021e3175cb80edc940592a;hpb=69c8aeb338cc485103e289fbab7ec4e7e056ed20;p=spider.git diff --git a/perl/DXUtil.pm b/perl/DXUtil.pm index 81bace8c..994cdd98 100644 --- a/perl/DXUtil.pm +++ b/perl/DXUtil.pm @@ -46,7 +46,7 @@ sub cldate my $t = shift; my ($sec,$min,$hour,$mday,$mon,$year) = gmtime((defined $t) ? $t : time); $year += 1900; - my $buf = sprintf "%02d-%s-%04d", $mday, $month[$mon], $year; + my $buf = sprintf "%2d-%s-%04d", $mday, $month[$mon], $year; return $buf; } @@ -148,11 +148,9 @@ sub print_all_fields { my $self = shift; # is a dxchan my $ref = shift; # is a thingy with field_prompt and fields methods defined - my @out = @_; - + my @out; my @fields = $ref->fields; my $field; - my @out; foreach $field (sort @fields) { if (defined $ref->{$field}) {