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

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

Issue 1135943002: Pull in various gpu/command_buffer fixes from chromium (Closed) Base URL: git@github.com:domokit/mojo.git@master
Patch Set: Created 5 years, 7 months 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_unittest.cc
diff --git a/gpu/command_buffer/client/gles2_implementation_unittest.cc b/gpu/command_buffer/client/gles2_implementation_unittest.cc
index 4fecbbc1781d3654b5a8951808558b8d884fc2f5..0b02f94897a5ed4bd92528bbfe12291bc924fb2e 100644
--- a/gpu/command_buffer/client/gles2_implementation_unittest.cc
+++ b/gpu/command_buffer/client/gles2_implementation_unittest.cc
@@ -51,13 +51,13 @@ template <typename T>
class SizedResultHelper {
public:
explicit SizedResultHelper(T result)
- : size_(sizeof(result)),
- result_(result) {
+ : size_(sizeof(result)) {
+ memcpy(result_, &result, sizeof(T));
}
private:
uint32 size_;
- T result_;
+ char result_[sizeof(T)];
};
// Struct to make it easy to pass a vec4 worth of floats.

Powered by Google App Engine
This is Rietveld 408576698