void CpDeviceList::Removed(CpiDevice& aDevice) { Brn udn(aDevice.Udn()); Map::iterator it = iMap.find(udn); if (it != iMap.end()) { CpDevice* device = it->second; iRemoved(*device); device->RemoveRef(); iMap.erase(it); } }
void DeviceListTI::Removed(CpDevice& aDevice) { if (iStopped) { return; } AutoMutex a(iLock); const TUint count = (TUint)iList.size(); for (TUint i=0; i<count; i++) { CpDevice* device = iList[i]; if (device->Udn() == aDevice.Udn()) { iList[i] = NULL; iList.erase(iList.begin()+i); device->RemoveRef(); break; } } }