Merge pull request #4125 from leoetlino/fix-iterate-crash InputConfigDiag: Fix a segfault caused by missing check