122 ENSURE_WRITTEN_BYTES(buffer, 10, 0, 0, 0x63, 0x69, 0xde, 0xad, 0xbe, 0xaf, 0, 0);
171 0x0123456789abcdefLLU,
172 "Could not read expected value");
182#if defined(__clang__)
183#if __has_warning("-Wself-assign-overloaded")
184#pragma clang diagnostic push
185#pragma clang diagnostic ignored "-Wself-assign-overloaded"
189#if defined(__clang__)
190#if __has_warning("-Wself-assign-overloaded")
191#pragma clang diagnostic pop
248 ENSURE_WRITTEN_BYTES(buffer, 11, 0x30, 0x31, 0x32, 0, 0, 0xac, 0xad, 0xae, 0xaf, 0xba, 0xbb);
297 for (
uint32_t i = 0; i < actualSize; i++)
299 iter.
WriteU8(
static_cast<uint8_t
>(bytesRng->GetValue()));
305 iter.
Prev(chunkSize);
338 ENSURE_WRITTEN_BYTES(buffer, 9, 0x1, 0x2, 0x00, 0x00, 0x00, 0x00, 0x00, 0x3, 0x4);
343 ENSURE_WRITTEN_BYTES(other, 9, 0x1, 0x2, 0x00, 0x00, 0x00, 0x00, 0x00, 0x3, 0x4);
346 std::string ct(
"This is the next content of the buffer.");
350 i.
Write((
const uint8_t*)ct.c_str(), ct.size());
353 const uint8_t* evilBuffer = buffer.
PeekData();
355 auto cBuf = (uint8_t*)malloc(sizeBuffer);
358 for (
uint32_t i = 0; i < sizeBuffer; i++)
361 *(((
const uint8_t*)ct.c_str()) + i),
362 "Bad buffer copied data");