fix9: trd attempt to make upload_file function not deadlockable