| Index: media/cdm/simple_cdm_buffer.cc | 
| diff --git a/media/cdm/simple_cdm_buffer.cc b/media/cdm/simple_cdm_buffer.cc | 
| index c5f3b8bbf96d0e88d159cb81d49e299a1ad148f8..712c8b7b03b5ac47ed7a8242e2792e1eaac3a987 100644 | 
| --- a/media/cdm/simple_cdm_buffer.cc | 
| +++ b/media/cdm/simple_cdm_buffer.cc | 
| @@ -4,14 +4,20 @@ | 
|  | 
| #include "media/cdm/simple_cdm_buffer.h" | 
|  | 
| +#include <limits> | 
| + | 
| #include "base/logging.h" | 
| +#include "base/numerics/safe_conversions.h" | 
|  | 
| namespace media { | 
|  | 
| // static | 
| -SimpleCdmBuffer* SimpleCdmBuffer::Create(uint32_t capacity) { | 
| +SimpleCdmBuffer* SimpleCdmBuffer::Create(size_t capacity) { | 
| DCHECK(capacity); | 
| -  return new SimpleCdmBuffer(capacity); | 
| + | 
| +  // cdm::Buffer interface limits capacity to uint32. | 
| +  DCHECK_LE(capacity, std::numeric_limits<uint32_t>::max()); | 
| +  return new SimpleCdmBuffer(base::checked_cast<uint32_t>(capacity)); | 
| } | 
|  | 
| SimpleCdmBuffer::SimpleCdmBuffer(uint32_t capacity) | 
|  |