File tree 1 file changed +7
-5
lines changed
1 file changed +7
-5
lines changed Original file line number Diff line number Diff line change @@ -232,12 +232,13 @@ void FdbOrch::update(sai_fdb_event_t type,
232
232
update.entry .mac .to_string ().c_str (),
233
233
vlanName.c_str (), update.port .m_alias .c_str ());
234
234
235
- for (const auto & itr : m_entries)
235
+ for (auto itr = m_entries. begin (); itr != m_entries. end (); )
236
236
{
237
- if (itr.port_name == update.port .m_alias )
237
+ auto next_item = std::next (itr);
238
+ if (itr->port_name == update.port .m_alias )
238
239
{
239
- update.entry .mac = itr. mac ;
240
- update.entry .bv_id = itr. bv_id ;
240
+ update.entry .mac = itr-> mac ;
241
+ update.entry .bv_id = itr-> bv_id ;
241
242
update.add = false ;
242
243
243
244
storeFdbEntryState (update);
@@ -246,7 +247,8 @@ void FdbOrch::update(sai_fdb_event_t type,
246
247
{
247
248
observer->update (SUBJECT_TYPE_FDB_CHANGE, &update);
248
249
}
249
- }
250
+ }
251
+ itr = next_item;
250
252
}
251
253
}
252
254
else if (bridge_port_id == SAI_NULL_OBJECT_ID)
You can’t perform that action at this time.
0 commit comments