in reply to Re: url file download code
in thread perl program to write a perl program

Thanks again guys... got that part working.
Now I have a faulty operater problem (me)....
sub calc_disk { my $md5_disk = undef; open(FILE, "/tmp/dl_mods/$filename") or die "md5sum cannot fin +d /tmp/dl_mods/$filename !!"; binmode(FILE); $md5_disk = Digest::MD5->new->addfile(*FILE)->hexdigest,"\n"; if ($@) { $errormessage = $@; $response_code = 0; return $response_code; } return ($md5_disk); }
What I get is this
Useless use of a constant in void context at dlfiles_sub.pl
line 98.
Digest::MD5->new->addfile(*FILE)->hexdigest,"\n";
Other than stripping that line out nothing fixes it
Well nothing between my ear's anyway.

Replies are listed 'Best First'.
Re^3: url file download code
by electroman00 (Novice) on Dec 23, 2006 at 10:49 UTC
    Well there was a lot of trees but no forest.
    $md5_disk = undef; open(FILE, "/tmp/dl_mods/$filename") or die "md5sum cannot fin +d /tmp/dl_mods/$filename !!"; binmode(FILE); $md5_disk = Digest::MD5->new->addfile(*FILE)->hexdigest; close(FILE);