#ifdef UNSAFE_BUFFERS_BUILD
#pragma allow_unsafe_buffers
#endif
#include "components/gwp_asan/common/pack_stack_trace.h"
namespace gwp_asan {
namespace internal {
namespace {
size_t VarIntEncode(uintptr_t value, uint8_t* out, size_t out_len) { … }
size_t VarIntDecode(const uint8_t* in, size_t in_len, uintptr_t* out) { … }
uintptr_t ZigzagEncode(uintptr_t value) { … }
uintptr_t ZigzagDecode(uintptr_t value) { … }
}
size_t Pack(const uintptr_t* unpacked,
size_t unpacked_size,
uint8_t* packed,
size_t packed_max_size) { … }
size_t Unpack(const uint8_t* packed,
size_t packed_size,
uintptr_t* unpacked,
size_t unpacked_max_size) { … }
}
}