aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/SFileReadFile.cpp7
-rw-r--r--src/StormPort.h4
2 files changed, 7 insertions, 4 deletions
diff --git a/src/SFileReadFile.cpp b/src/SFileReadFile.cpp
index a9d070f..192d212 100644
--- a/src/SFileReadFile.cpp
+++ b/src/SFileReadFile.cpp
@@ -886,10 +886,9 @@ DWORD WINAPI SFileSetFilePointer(HANDLE hFile, LONG lFilePos, LONG * plFilePosHi
if(!FileStream_Read(hf->pStream, &NewPosition, NULL, 0))
return SFILE_INVALID_POS;
}
- else
- {
- hf->dwFilePos = (DWORD)NewPosition;
- }
+
+ // Also, store the new file position to the TMPQFile struct
+ hf->dwFilePos = (DWORD)NewPosition;
// Return the new file position
if(plFilePosHigh != NULL)
diff --git a/src/StormPort.h b/src/StormPort.h
index ee00db8..aa5a52d 100644
--- a/src/StormPort.h
+++ b/src/StormPort.h
@@ -81,6 +81,10 @@
#include <unistd.h>
#include <fcntl.h>
#include <stdlib.h>
+ #include <stdio.h>
+ #include <string.h>
+ #include <ctype.h>
+ #include <assert.h>
#include <errno.h>
// Support for PowerPC on Max OS X