Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

32-bit MsgPack integers are not correctly unpacked into 64-bit values #14

Open
dinhngtu opened this issue Jun 13, 2022 · 0 comments
Open

Comments

@dinhngtu
Copy link

Hello,

cppack does not correctly unpack 32-bit MsgPack integers into 64-bit values.

Please see a minimal reproducer below:

std::array<uint64_t, 2> test_num = {65537, 65537};
packer.clear();
packer.process(test_num);
std::array<uint64_t, 2> x;
unpacker.set_data(packer.vector().data(), packer.vector().size());
unpacker.process(x);
REQUIRE(x[0] == 65537);
REQUIRE(x[1] == 65537);
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant