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

Unified Diff: gpu/command_buffer/client/gles2_implementation.cc

Issue 2528243002: Fix silent truncations when extracting values from CheckedNumeric (Closed)
Patch Set: compile cleanup and fix 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
Index: gpu/command_buffer/client/gles2_implementation.cc
diff --git a/gpu/command_buffer/client/gles2_implementation.cc b/gpu/command_buffer/client/gles2_implementation.cc
index 3424bc2a5310224463bbed535e1e84eed8e336d0..a624aa9356fd48a44e7ab753f2e5a625310ebcaf 100644
--- a/gpu/command_buffer/client/gles2_implementation.cc
+++ b/gpu/command_buffer/client/gles2_implementation.cc
@@ -6353,7 +6353,8 @@ bool GLES2Implementation::PackStringsToBucket(GLsizei count,
header[ii + 1] = len;
}
// Pack data into a bucket on the service.
- helper_->SetBucketSize(kResultBucketId, total_size.ValueOrDefault(0));
+ helper_->SetBucketSize(kResultBucketId,
+ total_size.template ValueOrDefault<uint32_t>(0));
size_t offset = 0;
for (GLsizei ii = 0; ii <= count; ++ii) {
const char* src =

Powered by Google App Engine
This is Rietveld 408576698