Better handle incorrect filenames.