0

Fix pdfium use of base/numerics

TBR=jochen@chromium.org
R=jochen@chromium.org
BUG=668713

Review-Url: https://codereview.chromium.org/2543443003
Cr-Commit-Position: refs/heads/master@{#435159}
This commit is contained in:
jschuh
2016-11-30 00:17:52 -08:00
committed by Commit bot
parent b540f4e1ae
commit dcffc76477

@ -42,8 +42,7 @@ class PDFiumAPIStringBufferAdapter {
template <typename IntType> template <typename IntType>
void Close(IntType actual_size) { void Close(IntType actual_size) {
base::CheckedNumeric<size_t> unsigned_size = actual_size; Close(base::checked_cast<size_t>(actual_size));
Close(unsigned_size.ValueOrDie());
} }
private: private:
@ -88,8 +87,7 @@ class PDFiumAPIStringBufferSizeInBytesAdapter {
template <typename IntType> template <typename IntType>
void Close(IntType actual_size) { void Close(IntType actual_size) {
base::CheckedNumeric<size_t> unsigned_size = actual_size; Close(base::checked_cast<size_t>(actual_size));
Close(unsigned_size.ValueOrDie());
} }
private: private: