Check the extension for a file name, and add if missing.
The name of the file.
The extension to check and add.
File name with the extension added.