Coverity scan compiler fix

This commit is contained in:
Markus Gans 2019-10-21 03:17:29 +02:00
parent 38d4fea995
commit ff39c85a33
1 changed files with 5 additions and 4 deletions

View File

@ -223,16 +223,17 @@ void FMenuItem::delAccelerator (FWidget* obj)
auto root = getRootWidget();
if ( root
&& ! root->getAcceleratorList().empty() )
&& ! root->setAcceleratorList().empty() )
{
auto iter = root->setAcceleratorList().begin();
auto list = root->setAcceleratorList();
auto iter = list.begin();
while ( iter != root->getAcceleratorList().end() )
while ( iter != list.end() )
{
if ( iter->object == obj )
{
accel_key = 0;
iter = root->setAcceleratorList().erase(iter);
iter = list.erase(iter);
}
else
++iter;