Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(209)

Unified Diff: third_party/WebKit/Source/modules/mediasource/TrackDefaultList.cpp

Issue 2671933002: Migrate WTF::HashMap::add() to ::insert() (Closed)
Patch Set: rebase, add TODOs Created 3 years, 10 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: third_party/WebKit/Source/modules/mediasource/TrackDefaultList.cpp
diff --git a/third_party/WebKit/Source/modules/mediasource/TrackDefaultList.cpp b/third_party/WebKit/Source/modules/mediasource/TrackDefaultList.cpp
index dac4d2e06df0e966fcfa20445aae8dc88b47398f..8aa754a01f0397605f9f3e3d1a599c70c24057ae 100644
--- a/third_party/WebKit/Source/modules/mediasource/TrackDefaultList.cpp
+++ b/third_party/WebKit/Source/modules/mediasource/TrackDefaultList.cpp
@@ -35,7 +35,7 @@ TrackDefaultList* TrackDefaultList::create(
for (const auto& trackDefault : trackDefaults) {
TypeAndID key =
TypeAndID(trackDefault->type(), trackDefault->byteStreamTrackID());
- if (!typeAndIDToTrackDefaultMap.add(key, trackDefault).isNewEntry) {
+ if (!typeAndIDToTrackDefaultMap.insert(key, trackDefault).isNewEntry) {
exceptionState.throwDOMException(
InvalidAccessError, "Duplicate TrackDefault type (" + key.first +
") and byteStreamTrackID (" + key.second +

Powered by Google App Engine
This is Rietveld 408576698