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

Unified Diff: media/cdm/cenc_utils.cc

Issue 1471043004: Convert various vector_as_array calls to vector::data. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 5 years, 1 month 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/cdm/ppapi/external_clear_key/clear_key_cdm.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: media/cdm/cenc_utils.cc
diff --git a/media/cdm/cenc_utils.cc b/media/cdm/cenc_utils.cc
index 357bb6a688fb5e445457727ff8c86ce50b12bd7a..cb7373f00c87dbd4e97778128508bfdc3eaa38c1 100644
--- a/media/cdm/cenc_utils.cc
+++ b/media/cdm/cenc_utils.cc
@@ -4,7 +4,6 @@
#include "media/cdm/cenc_utils.h"
-#include "base/stl_util.h"
#include "media/formats/mp4/box_definitions.h"
#include "media/formats/mp4/box_reader.h"
@@ -38,8 +37,7 @@ static bool ReadAllPsshBoxes(
// so this simply verifies that |input| only contains 'pssh' boxes and
// nothing else.
scoped_ptr<mp4::BoxReader> input_reader(
- mp4::BoxReader::ReadConcatentatedBoxes(
- vector_as_array(&input), input.size()));
+ mp4::BoxReader::ReadConcatentatedBoxes(input.data(), input.size()));
std::vector<mp4::ProtectionSystemSpecificHeader> raw_pssh_boxes;
if (!input_reader->ReadAllChildrenAndCheckFourCC(&raw_pssh_boxes))
return false;
@@ -51,9 +49,8 @@ static bool ReadAllPsshBoxes(
// ignoring any boxes that can't be parsed.
for (const auto& raw_pssh_box : raw_pssh_boxes) {
scoped_ptr<mp4::BoxReader> raw_pssh_reader(
- mp4::BoxReader::ReadConcatentatedBoxes(
- vector_as_array(&raw_pssh_box.raw_box),
- raw_pssh_box.raw_box.size()));
+ mp4::BoxReader::ReadConcatentatedBoxes(raw_pssh_box.raw_box.data(),
+ raw_pssh_box.raw_box.size()));
// ReadAllChildren() appends any successfully parsed box onto it's
// parameter, so |pssh_boxes| will contain the collection of successfully
// parsed 'pssh' boxes. If an error occurs, try the next box.
« no previous file with comments | « media/cdm/cdm_adapter.cc ('k') | media/cdm/ppapi/external_clear_key/clear_key_cdm.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698