=================================================================== RCS file: /cvs/openbsd/OpenBSDTorrents/ServerTorrents.pl,v retrieving revision 1.8 retrieving revision 1.9 diff -u -r1.8 -r1.9 --- openbsd/OpenBSDTorrents/ServerTorrents.pl 2005/04/01 01:20:15 1.8 +++ openbsd/OpenBSDTorrents/ServerTorrents.pl 2005/04/04 03:14:17 1.9 @@ -1,5 +1,5 @@ #!/usr/bin/perl -T -#$Id: ServerTorrents.pl,v 1.8 2005/04/01 01:20:15 andrew Exp $ +#$Id: ServerTorrents.pl,v 1.9 2005/04/04 02:14:17 andrew Exp $ use strict; use warnings; use diagnostics; @@ -65,6 +65,8 @@ my ($name, $year, $mon, $mday, $hour, $min) = /^(.*)-(\d{4})-(\d{2})-(\d{2})-(\d{2})(\d{2})/; + my $time = "$year.$mon.$mday $hour:$min"; + $mon--; my $epoch = timegm(0,$min,$hour,$mday,$mon,$year); @@ -76,6 +78,7 @@ mday => $mday, hour => $hour, min => $min, + time => $time, epoch => $epoch, }; @@ -90,14 +93,14 @@ #print "\t$epoch\n"; my $torrent = $files{$name}{$epoch}{file}; unless (exists $server_torrents{$torrent} ) { - my $time = - $files{$name}{$epoch}{year} . '-' . - $files{$name}{$epoch}{mon} . '-' . - $files{$name}{$epoch}{mday} . ' ' . - $files{$name}{$epoch}{hour} . ':' . - $files{$name}{$epoch}{min} . ':00'; + #my $time = + # $files{$name}{$epoch}{year} . '-' . + # $files{$name}{$epoch}{mon} . '-' . + # $files{$name}{$epoch}{mday} . ' ' . + # $files{$name}{$epoch}{hour} . ':' . + # $files{$name}{$epoch}{min} . ':00'; - Upload_Torrent($torrent, $time); + Upload_Torrent($torrent, $files{$name}{$epoch}{time}); } next; }