mirror of
https://github.com/baldurk/renderdoc.git
synced 2026-05-04 17:10:47 +00:00
Fix access to array after target element has been removed
This commit is contained in:
@@ -298,8 +298,13 @@ void PersistantConfig::UpdateEnumeratedProtocolDevices()
|
||||
QMap<rdcstr, RemoteHost> oldHosts;
|
||||
|
||||
for(int i = RemoteHostList.count() - 1; i >= 0; i--)
|
||||
{
|
||||
if(RemoteHostList[i].Protocol())
|
||||
oldHosts[RemoteHostList[i].Hostname()] = RemoteHostList.takeAt(i);
|
||||
{
|
||||
RemoteHost host = RemoteHostList.takeAt(i);
|
||||
oldHosts[host.Hostname()] = host;
|
||||
}
|
||||
}
|
||||
|
||||
for(RemoteHost host : enumeratedDevices)
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user