open(TMP, ">$files_path/$tm-$i.$type") || error(...); binmode(TMP); print TMP "$fl"; close TMP;