Skip to content

Commit f4efd0f

Browse files
edsilegxreposebres
authored andcommitted
SFXSetup/SfxSetup.cpp: trying to fix hypothetical BO introduced in v.26.00,
applied patch provided by mshedsilegx in #468 (comment)
1 parent c132094 commit f4efd0f

1 file changed

Lines changed: 2 additions & 2 deletions

File tree

CPP/7zip/Bundles/SFXSetup/SfxSetup.cpp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -71,7 +71,7 @@ static bool ReadDataString(CFSTR fileName, LPCSTR startID,
7171
{
7272
if (writeMode)
7373
{
74-
if (pos + signatureEndSize > numBytesPrev)
74+
if (pos + signatureEndSize >= numBytesPrev)
7575
break;
7676
const Byte b = buffer[pos++];
7777
if (b == 0)
@@ -82,7 +82,7 @@ static bool ReadDataString(CFSTR fileName, LPCSTR startID,
8282
}
8383
else
8484
{
85-
if (pos + signatureStartSize > numBytesPrev)
85+
if (pos + signatureStartSize >= numBytesPrev)
8686
break;
8787
const Byte b = buffer[pos++];
8888
if (b == ';' && memcmp(buffer + pos, startID + 1, signatureStartSize) == 0)

0 commit comments

Comments
 (0)