Check validity of new file names.