Skip to content

Commit

Permalink
Merge pull request #54 from reventlov/fix_uninitialized_memory_in_test
Browse files Browse the repository at this point in the history
Fix uninitialized memory in test code.
  • Loading branch information
AaronWebster authored Sep 7, 2022
2 parents a761f62 + b27fd7a commit 2c22275
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion compiler/back_end/cpp/testcode/uint_sizes_test.cc
Original file line number Diff line number Diff line change
Expand Up @@ -360,7 +360,7 @@ TEST(SizesView, CanReadExplicitlySizedEnumSizes) {
}

TEST(SizesWriter, CanWriteExplicitlySizedEnumSizes) {
::std::uint8_t buffer[sizeof kExplicitlySizedEnumSizes];
::std::uint8_t buffer[sizeof kExplicitlySizedEnumSizes] = {0};
auto writer = ExplicitlySizedEnumSizesWriter(buffer, sizeof buffer);
writer.one_byte().Write(ExplicitlySizedEnum::VALUE1);
writer.two_byte().Write(ExplicitlySizedEnum::VALUE10);
Expand Down

0 comments on commit 2c22275

Please sign in to comment.