[Scummvm-cvs-logs] SF.net SVN: scummvm: [32634] scummvm/trunk/engines/drascula

thebluegr at users.sourceforge.net thebluegr at users.sourceforge.net
Mon Jun 9 16:23:05 CEST 2008


Revision: 32634
          http://scummvm.svn.sourceforge.net/scummvm/?rev=32634&view=rev
Author:   thebluegr
Date:     2008-06-09 07:23:04 -0700 (Mon, 09 Jun 2008)

Log Message:
-----------
Bugfix to read the first array element correctly by sev

Modified Paths:
--------------
    scummvm/trunk/engines/drascula/drascula.cpp
    scummvm/trunk/engines/drascula/drascula.h

Modified: scummvm/trunk/engines/drascula/drascula.cpp
===================================================================
--- scummvm/trunk/engines/drascula/drascula.cpp	2008-06-09 14:21:32 UTC (rev 32633)
+++ scummvm/trunk/engines/drascula/drascula.cpp	2008-06-09 14:23:04 UTC (rev 32634)
@@ -930,10 +930,11 @@
 		res[lang] = (char **)malloc(sizeof(char *) * numTexts);
 
 		res[lang][0] = pos = (char *)malloc(entryLen);
+		res[lang][0] = pos + DATAALIGNMENT;
 
 		in.read(res[lang][0], entryLen);
 
-		pos += 4;
+		pos += DATAALIGNMENT;
 
 		for (int i = 1; i < numTexts; i++) {
 			pos -= 2;

Modified: scummvm/trunk/engines/drascula/drascula.h
===================================================================
--- scummvm/trunk/engines/drascula/drascula.h	2008-06-09 14:21:32 UTC (rev 32633)
+++ scummvm/trunk/engines/drascula/drascula.h	2008-06-09 14:23:04 UTC (rev 32634)
@@ -48,6 +48,7 @@
 
 // Do not update this yet. The file is not loaded fully
 #define DRASCULA_DAT_VER 1
+#define DATAALIGNMENT 4
 
 enum DrasculaGameFeatures {
 	GF_PACKED = (1 << 0)


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