Current News
Archived News
Search News
Discussion Forum


Old Forum
Install Programs More Downloads...
Troubleshooting
Source Code
Format Specs.
Misc. Information
Non-SF Stuff
Links




ShadowFlare [Wed, 15 Aug 2012 07:41:06 +0000 (01:41 -0600)]
1  2 
SFUtil.cpp
SFmpqapi.cpp

diff --cc SFUtil.cpp
Simple merge
diff --cc SFmpqapi.cpp
@@@ -2555,10 -2575,10 +2557,10 @@@ BOOL SFMPQAPI WINAPI MpqCompactArchive(
        char *lpFileName = (char *)NewAlloc.Alloc(strlen(mpqOpenArc->lpFileName)+13);
        sprintf(lpFileName,"%s.compact",mpqOpenArc->lpFileName);
        HANDLE hFile = CreateFile(lpFileName,GENERIC_READ|GENERIC_WRITE,0,0,CREATE_NEW,0,0);
 -      DWORD i;
 +      UInt64 i;
        if (hFile==INVALID_HANDLE_VALUE) {
                for (i=0;i<10000;i++) {
-                       sprintf(lpFileName,"%s.compact.%04ld",mpqOpenArc->lpFileName,i);
+                       sprintf(lpFileName,"%s.compact.%04d",mpqOpenArc->lpFileName,i);
  
                        hFile = CreateFile(lpFileName,GENERIC_READ|GENERIC_WRITE,0,0,CREATE_NEW,0,0);
                        if (hFile!=INVALID_HANDLE_VALUE) break;