[Scummvm-cvs-logs] CVS: scummvm/scumm script_v6.cpp,1.89,1.90

Nicolas Bacca arisme at users.sourceforge.net
Sun Apr 6 05:58:02 CEST 2003


Update of /cvsroot/scummvm/scummvm/scumm
In directory sc8-pr-cvs1:/tmp/cvs-serv10088

Modified Files:
	script_v6.cpp 
Log Message:
Alignment fix

Index: script_v6.cpp
===================================================================
RCS file: /cvsroot/scummvm/scummvm/scumm/script_v6.cpp,v
retrieving revision 1.89
retrieving revision 1.90
diff -u -d -r1.89 -r1.90
--- script_v6.cpp	1 Apr 2003 20:56:27 -0000	1.89
+++ script_v6.cpp	6 Apr 2003 12:57:25 -0000	1.90
@@ -423,9 +423,18 @@
 	if (ah->type == 4) {
 		ah->data[base] = value;
 	} else if (_features & GF_AFTER_V8) {
+#if defined(SCUMM_NEED_ALIGNMENT)
+		memcpy(&ah->data[base], &TO_LE_32(value), 4);
+#else
 		((uint32 *)ah->data)[base] = TO_LE_32(value);
+#endif
+		
 	} else {
+#if defined(SCUMM_NEED_ALIGNMENT)
+		memcpy(&ah->data[base], &TO_LE_16(value), 2);
+#else
 		((uint16 *)ah->data)[base] = TO_LE_16(value);
+#endif
 	}
 }
 





More information about the Scummvm-git-logs mailing list