pub fn close_file_by_name(filename: &str) -> Result<()>
Closes a file by its filename.
Only works if the name matches the one used to open the file.