Qt: Fix crash when loading input profile and multitap disabled

This commit is contained in:
Connor McLaughlin 2021-03-05 00:58:48 +10:00
parent c8387cb038
commit ccda1553b7
1 changed files with 3 additions and 0 deletions

View File

@ -118,6 +118,9 @@ void ControllerSettingsWidget::onProfileLoaded()
{ {
for (int i = 0; i < static_cast<int>(m_port_ui.size()); i++) for (int i = 0; i < static_cast<int>(m_port_ui.size()); i++)
{ {
if (!m_port_ui[i].widget)
continue;
ControllerType ctype = Settings::ParseControllerTypeName( ControllerType ctype = Settings::ParseControllerTypeName(
m_host_interface m_host_interface
->GetStringSettingValue(QStringLiteral("Controller%1").arg(i + 1).toStdString().c_str(), ->GetStringSettingValue(QStringLiteral("Controller%1").arg(i + 1).toStdString().c_str(),