1
0
mirror of synced 2024-11-28 17:40:51 +01:00

fix: Potential error when parsing Intel Hex and Motorola SREC files

This commit is contained in:
WerWolv 2023-11-17 15:01:57 +01:00
parent cec925bcdc
commit 1f05deddc8
2 changed files with 2 additions and 2 deletions

View File

@ -49,7 +49,7 @@ namespace hex::plugin::builtin {
} recordType; } recordType;
auto c = [&] { auto c = [&] {
while (std::isspace(string[offset]) && offset < string.length()) while (offset < string.length() && std::isspace(string[offset]))
offset++; offset++;
if (offset >= string.length()) if (offset >= string.length())

View File

@ -34,7 +34,7 @@ namespace hex::plugin::builtin {
std::vector<u8> data; std::vector<u8> data;
auto c = [&] { auto c = [&] {
while (std::isspace(string[offset]) && offset < string.length()) while (offset < string.length() && std::isspace(string[offset]))
offset++; offset++;
if (offset >= string.length()) if (offset >= string.length())