This is strange - I just tested it once again using dummy data and it works for me. Note that the comparison used to determine whether a given file has already been downloaded is (case sensitive) string equality, so preparing lastupdate.txt by hand is likely to fail - it shouldn't ignore the files it added itself though. If this is a problem, you might want to add some kind of canonicalisation step like
chomp( @lupd = map lc, <LASTUPDATE> );
...
next if $haveit{ lc $file }
to ignore case.
In any case, I'd recommend you to step it through with the debugger, checking the exact contents of the data structures at any time. This should give enough information to get things working.