Index: media/base/data_buffer.cc |
diff --git a/media/base/data_buffer.cc b/media/base/data_buffer.cc |
index 9d6afaf8d2f4e2ce7d964f2b2a47875683c39b1f..3879969b982bd8e1dafe5875ede8d35bc251dfbd 100644 |
--- a/media/base/data_buffer.cc |
+++ b/media/base/data_buffer.cc |
@@ -4,41 +4,37 @@ |
#include "media/base/data_buffer.h" |
- |
namespace media { |
DataBuffer::DataBuffer(int buffer_size) |
: buffer_size_(buffer_size), |
data_size_(0) { |
CHECK_GE(buffer_size, 0); |
- data_.reset(new uint8[buffer_size_]); |
+ data_.reset(new uint8_t[buffer_size_]); |
} |
-DataBuffer::DataBuffer(scoped_ptr<uint8[]> buffer, int buffer_size) |
- : data_(buffer.Pass()), |
- buffer_size_(buffer_size), |
- data_size_(buffer_size) { |
+DataBuffer::DataBuffer(scoped_ptr<uint8_t[]> buffer, int buffer_size) |
+ : data_(buffer.Pass()), buffer_size_(buffer_size), data_size_(buffer_size) { |
CHECK(data_.get()); |
CHECK_GE(buffer_size, 0); |
} |
-DataBuffer::DataBuffer(const uint8* data, int data_size) |
- : buffer_size_(data_size), |
- data_size_(data_size) { |
+DataBuffer::DataBuffer(const uint8_t* data, int data_size) |
+ : buffer_size_(data_size), data_size_(data_size) { |
if (!data) { |
CHECK_EQ(data_size, 0); |
return; |
} |
CHECK_GE(data_size, 0); |
- data_.reset(new uint8[buffer_size_]); |
+ data_.reset(new uint8_t[buffer_size_]); |
memcpy(data_.get(), data, data_size_); |
} |
DataBuffer::~DataBuffer() {} |
// static |
-scoped_refptr<DataBuffer> DataBuffer::CopyFrom(const uint8* data, int size) { |
+scoped_refptr<DataBuffer> DataBuffer::CopyFrom(const uint8_t* data, int size) { |
// If you hit this CHECK you likely have a bug in a demuxer. Go fix it. |
CHECK(data); |
return make_scoped_refptr(new DataBuffer(data, size)); |