in reply to Re^2: use of uninitialised value
in thread use of uninitialised value

Thank you. My error comes from the lack of fully written sample:
my $filename = "$upload_dir/$filename"; -d $upload_dir or die "$upload_dir: $!"; -f $filename or die "$filename: $!"; # I'm not in the secret why those endless absolute # filepaths are scattered almost always