[Scummvm-cvs-logs] SF.net SVN: scummvm: [22474] residual/trunk/lua.cpp

aquadran at users.sourceforge.net aquadran at users.sourceforge.net
Sun May 14 09:36:18 CEST 2006


Revision: 22474
Author:   aquadran
Date:     2006-05-14 09:18:54 -0700 (Sun, 14 May 2006)
ViewCVS:  http://svn.sourceforge.net/scummvm/?rev=22474&view=rev

Log Message:
-----------
fixed filefindnext opcode for Windows

Modified Paths:
--------------
    residual/trunk/lua.cpp
Modified: residual/trunk/lua.cpp
===================================================================
--- residual/trunk/lua.cpp	2006-05-14 15:13:22 UTC (rev 22473)
+++ residual/trunk/lua.cpp	2006-05-14 16:18:54 UTC (rev 22474)
@@ -2043,13 +2043,14 @@
 	if (g_searchFile) {
 #ifdef _WIN32
 		if (g_firstFind) {
+			g_firstFind = false;
 			found = true;
-			g_firstFind = false;
+		} else {
+			do {
+				if (FindNextFile(g_searchFile, &g_find_file_data) != 0)
+					found = true;
+			} while (found && (g_find_file_data.dwFileAttributes & FILE_ATTRIBUTE_DIRECTORY));
 		}
-		while (found && (g_find_file_data.dwFileAttributes & FILE_ATTRIBUTE_DIRECTORY)) {
-			if (FindNextFile(g_searchFile, &g_find_file_data) == 0)
-				found = true;
-		};
 #else
 		do {
 			de = readdir(g_searchFile);


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