Skip to content

Commit

Permalink
Merge pull request #55 from cdyk/32bit-offset
Browse files Browse the repository at this point in the history
Only compare lower 32 bits of offset since expected offset is a 32 bi…
  • Loading branch information
cdyk authored Dec 21, 2022
2 parents 901f0d6 + 6178db3 commit 02f6fa8
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/ParserRVM.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -99,7 +99,7 @@ namespace {
bool verifyOffset(Context* ctx, const char* chunk_type, const char* base_ptr, const char* curr_ptr, uint32_t expected_next_chunk_offset)
{
size_t current_offset = curr_ptr - base_ptr;
if (current_offset == expected_next_chunk_offset) {
if (static_cast<uint32_t>(current_offset) == expected_next_chunk_offset) {
return true;
}
else {
Expand Down

0 comments on commit 02f6fa8

Please sign in to comment.