Parcourir la source

LWO: ignore chunks of length zero.

Alexander Gessler il y a 12 ans
Parent
commit
e9ffabbfee
1 fichiers modifiés avec 5 ajouts et 0 suppressions
  1. 5 0
      code/LWOLoader.cpp

+ 5 - 0
code/LWOLoader.cpp

@@ -1296,6 +1296,11 @@ void LWOImporter::LoadLWO2File()
 		uint8_t* const next = mFileBuffer+head->length;
 		uint8_t* const next = mFileBuffer+head->length;
 		unsigned int iUnnamed = 0;
 		unsigned int iUnnamed = 0;
 
 
+		if(!head->length) {
+			mFileBuffer = next;
+			continue;
+		}
+
 		switch (head->type)
 		switch (head->type)
 		{
 		{
 			// new layer
 			// new layer