Checks that the icon file extension matches the actual image format in the file

Ensures that icons have the correct file extension (e.g. a .png file is really in the PNG format and not for example a GIF file named .png.)