Properly remove adb DNS services.
Bug: b/150136878 Bug: b/111434128 Test: make Change-Id: Ibfb92a7c197a25fd1913107d277fbc5f78108c05
This commit is contained in:
parent
bdbd0dde26
commit
79a452a923
1 changed files with 3 additions and 3 deletions
|
@ -409,9 +409,9 @@ static void adb_RemoveDNSService(const char* regType, const char* serviceName) {
|
|||
}
|
||||
|
||||
std::string sName(serviceName);
|
||||
std::remove_if(services->begin(), services->end(), [&sName](ResolvedService* service) {
|
||||
return (sName == service->serviceName());
|
||||
});
|
||||
services->erase(std::remove_if(
|
||||
services->begin(), services->end(),
|
||||
[&sName](ResolvedService* service) { return (sName == service->serviceName()); }));
|
||||
}
|
||||
|
||||
// Returns the version the device wanted to advertise,
|
||||
|
|
Loading…
Reference in a new issue