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

Unified Diff: components/nacl/browser/pnacl_host.cc

Issue 2536373003: Fix pnacl use of base/numerics (Closed)
Patch Set: Created 4 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 | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: components/nacl/browser/pnacl_host.cc
diff --git a/components/nacl/browser/pnacl_host.cc b/components/nacl/browser/pnacl_host.cc
index 1dacf669a9ea96ae519c28607b1698c35e7958a0..605d7d71d049fe9dd14c96765da8cbff55027f25 100644
--- a/components/nacl/browser/pnacl_host.cc
+++ b/components/nacl/browser/pnacl_host.cc
@@ -418,8 +418,8 @@ scoped_refptr<net::DrainableIOBuffer> PnaclHost::CopyFileToBuffer(
}
buffer = new net::DrainableIOBuffer(
- new net::IOBuffer(base::CheckedNumeric<size_t>(file_size).ValueOrDie()),
- base::CheckedNumeric<size_t>(file_size).ValueOrDie());
+ new net::IOBuffer(base::checked_cast<size_t>(file_size)),
+ base::checked_cast<size_t>(file_size));
if (file->Read(0, buffer->data(), buffer->size()) != file_size) {
PLOG(ERROR) << "CopyFileToBuffer file read failed";
buffer = nullptr;
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698