| Index: webrtc/api/jsepicecandidate.cc
|
| diff --git a/webrtc/api/jsepicecandidate.cc b/webrtc/api/jsepicecandidate.cc
|
| index 2aabcb83498ead96000f9624b423a21102516bfb..580ed33edfbe8f128a96869518a14ddd6c422cae 100644
|
| --- a/webrtc/api/jsepicecandidate.cc
|
| +++ b/webrtc/api/jsepicecandidate.cc
|
| @@ -79,4 +79,14 @@ bool JsepCandidateCollection::HasCandidate(
|
| return ret;
|
| }
|
|
|
| +int JsepCandidateCollection::remove(const IceCandidateInterface* candidate) {
|
| + size_t original_size = candidates_.size();
|
| + auto new_end = std::remove_if(
|
| + candidates_.begin(), candidates_.end(), [candidate](JsepIceCandidate* c) {
|
| + return candidate->candidate().MatchesForRemoval(c->candidate());
|
| + });
|
| + candidates_.erase(new_end, candidates_.end());
|
| + return static_cast<int>(original_size - candidates_.size());
|
| +}
|
| +
|
| } // namespace webrtc
|
|
|