From: ShadowFlare Date: Wed, 6 Jan 2010 06:26:20 +0000 (-0700) Subject: Used an incorrect variable for the parent archive in SFileOpenFileAsArchive. X-Git-Url: https://sfsrealm.hopto.org/projects/?a=commitdiff_plain;h=cd5a40ab4404ee1b938562561d9f9a40dd3dab75;p=SFmpqapi.git Used an incorrect variable for the parent archive in SFileOpenFileAsArchive. --- diff --git a/SFmpqapi.cpp b/SFmpqapi.cpp index fecddf9..0f5acaf 100644 --- a/SFmpqapi.cpp +++ b/SFmpqapi.cpp @@ -564,7 +564,7 @@ BOOL SFMPQAPI WINAPI SFileOpenFileAsArchive(MPQHANDLE hSourceMPQ, LPCSTR lpFileN } DWORD dwMpqStart; MPQARCHIVE *mpqOpenArc; - dwMpqStart = mpqOpenArc->dwMPQStart + mpqArcFile.lpBlockEntry->dwFileOffset; + dwMpqStart = mpqArcFile.lpParentArc->dwMPQStart + mpqArcFile.lpBlockEntry->dwFileOffset; flen = mpqArcFile.lpBlockEntry->dwFullSize; dwMpqStart = FindMpqHeaderAtLocation(hFile,dwMpqStart,flen); if (dwMpqStart==0xFFFFFFFF) {