Fix cppcheck warnings.

Refs #10061
Merge branch 'feature/10061_fits_loader' into develop