Skip to content

Commit

Permalink
fix null terminate search
Browse files Browse the repository at this point in the history
  • Loading branch information
tihmstar committed Aug 20, 2024
1 parent d12f088 commit 0141ec2
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions tools/binrider/main.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -165,8 +165,8 @@ int main_r(int argc, const char * argv[]) {
.data = {str.begin(), str.end()},
.isString = true,
};
if (!isNullTerminated && mLoc.data.size()) {
mLoc.data.pop_back();
if (isNullTerminated) {
mLoc.data.push_back('\0');
}
memLocs.push_back(mLoc);
}else if (curopt == "xref") {
Expand Down

0 comments on commit 0141ec2

Please sign in to comment.