fixed the case where filenames contain stupid spaces