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

Unified Diff: media/cdm/ppapi/external_clear_key/clear_key_cdm.cc

Issue 2895573002: Reland of Remove ScopedVector from all other codes in media/ (Closed)
Patch Set: Fix the compile fails in build target "jpeg_decode_accelerator_unittest" Created 3 years, 7 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
« no previous file with comments | « media/cdm/cdm_adapter.cc ('k') | media/formats/webm/opus_packet_builder.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: media/cdm/ppapi/external_clear_key/clear_key_cdm.cc
diff --git a/media/cdm/ppapi/external_clear_key/clear_key_cdm.cc b/media/cdm/ppapi/external_clear_key/clear_key_cdm.cc
index b6c1934b33adb2957006c7332dc414e2724fe00e..9ceaf14c47152eae78212ca497c5d5d2cac002ba 100644
--- a/media/cdm/ppapi/external_clear_key/clear_key_cdm.cc
+++ b/media/cdm/ppapi/external_clear_key/clear_key_cdm.cc
@@ -206,7 +206,7 @@ cdm::KeyStatus ConvertKeyStatus(media::CdmKeyInformation::KeyStatus status) {
// Shallow copy all the key information from |keys_info| into |keys_vector|.
// |keys_vector| is only valid for the lifetime of |keys_info| because it
// contains pointers into the latter.
-void ConvertCdmKeysInfo(const std::vector<media::CdmKeyInformation*>& keys_info,
+void ConvertCdmKeysInfo(const media::CdmKeysInfo& keys_info,
std::vector<cdm::KeyInformation>* keys_vector) {
keys_vector->reserve(keys_info.size());
for (const auto& key_info : keys_info) {
@@ -868,7 +868,7 @@ void ClearKeyCdm::OnSessionKeysChange(const std::string& session_id,
}
std::vector<cdm::KeyInformation> keys_vector;
- ConvertCdmKeysInfo(keys_info.get(), &keys_vector);
+ ConvertCdmKeysInfo(keys_info, &keys_vector);
host_->OnSessionKeysChange(new_session_id.data(), new_session_id.length(),
has_additional_usable_key, keys_vector.data(),
keys_vector.size());
@@ -943,7 +943,7 @@ void ClearKeyCdm::OnLoadSessionUpdated() {
keys_info.swap(keys_info_for_emulated_loadsession_);
has_received_keys_change_event_for_emulated_loadsession_ = false;
DCHECK(!keys_vector.empty());
- ConvertCdmKeysInfo(keys_info.get(), &keys_vector);
+ ConvertCdmKeysInfo(keys_info, &keys_vector);
host_->OnSessionKeysChange(kLoadableSessionId, strlen(kLoadableSessionId),
!keys_vector.empty(), keys_vector.data(),
keys_vector.size());
« no previous file with comments | « media/cdm/cdm_adapter.cc ('k') | media/formats/webm/opus_packet_builder.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698