[Scummvm-cvs-logs] SF.net SVN: scummvm:[33108] scummvm/trunk/backends/platform/symbian/src/ SymbianOS.cpp

anotherguest at users.sourceforge.net anotherguest at users.sourceforge.net
Sat Jul 19 09:08:38 CEST 2008


Revision: 33108
          http://scummvm.svn.sourceforge.net/scummvm/?rev=33108&view=rev
Author:   anotherguest
Date:     2008-07-19 07:08:37 +0000 (Sat, 19 Jul 2008)

Log Message:
-----------
eof was not working properly with caching

Modified Paths:
--------------
    scummvm/trunk/backends/platform/symbian/src/SymbianOS.cpp

Modified: scummvm/trunk/backends/platform/symbian/src/SymbianOS.cpp
===================================================================
--- scummvm/trunk/backends/platform/symbian/src/SymbianOS.cpp	2008-07-19 00:57:37 UTC (rev 33107)
+++ scummvm/trunk/backends/platform/symbian/src/SymbianOS.cpp	2008-07-19 07:08:37 UTC (rev 33108)
@@ -597,13 +597,18 @@
 
 bool symbian_feof(FILE* handle) {
 	TInt pos = 0;
+	TSymbianFileEntry* entry = ((TSymbianFileEntry*)(handle));
 
-	if (((TSymbianFileEntry*)(handle))->iFileHandle.Seek(ESeekCurrent, pos) == KErrNone) {
+	if (entry->iFileHandle.Seek(ESeekCurrent, pos) == KErrNone) {
 
 		TInt size = 0;
-		if (((TSymbianFileEntry*)(handle))->iFileHandle.Size(size) == KErrNone) {
-			if (pos == size)
+		if (entry->iFileHandle.Size(size) == KErrNone) {
+			if(entry->iInputPos == KErrNotFound && pos == size) 			
 				return true;
+
+			if(entry->iInputPos != KErrNotFound && pos == size && entry->iInputPos == entry->iInputBufferLen)
+				return true;
+
 			return false;
 		}
 	}


This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.




More information about the Scummvm-git-logs mailing list