Skip to content

Commit

Permalink
Merge pull request #79 from e8tools/feature/broken-name-fix-issue78
Browse files Browse the repository at this point in the history
Fix #78 Чтение имени до нулевого символа.
  • Loading branch information
dmpas authored Mar 16, 2022
2 parents 69eb7cf + 1a022e9 commit 07f9af1
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions src/V8File.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -65,9 +65,10 @@ string CV8Elem::GetName() const

auto currentChar = header.data() + CV8Elem::stElemHeaderBegin::Size();
for (int j = 0; j < ElemNameLen * 2; j += 2, currentChar += 2) {
if (*currentChar != '\0') {
ss << *currentChar;
if (*currentChar == '\0') {
break;
}
ss << *currentChar;
}

return ss.str();
Expand Down

0 comments on commit 07f9af1

Please sign in to comment.