| Index: tests/ImageIsOpaqueTest.cpp
|
| diff --git a/tests/ImageIsOpaqueTest.cpp b/tests/ImageIsOpaqueTest.cpp
|
| index 6fdbc8127abf4a4165c238393771af29f5cd78bd..6d886d48bfb19e05b40cb4e8f5dab86f58dcea24 100644
|
| --- a/tests/ImageIsOpaqueTest.cpp
|
| +++ b/tests/ImageIsOpaqueTest.cpp
|
| @@ -17,8 +17,8 @@
|
| #include "SkWriteBuffer.h"
|
|
|
| static void test_flatten(skiatest::Reporter* reporter, const SkImageInfo& info) {
|
| - // just need a safe amount of storage
|
| - char storage[sizeof(SkImageInfo)*2];
|
| + // just need a safe amount of storage, but ensure that it is 4-byte aligned.
|
| + int32_t storage[(sizeof(SkImageInfo)*2) / sizeof(int32_t)];
|
| SkWriteBuffer wb(storage, sizeof(storage));
|
| info.flatten(wb);
|
| SkASSERT(wb.bytesWritten() < sizeof(storage));
|
|
|