소스 검색

Fixed crash with no newline at start of atlas.

NathanSweet 12 년 전
부모
커밋
e1b7b713a2
1개의 변경된 파일2개의 추가작업 그리고 3개의 파일을 삭제
  1. 2 3
      spine-csharp/src/Atlas.cs

+ 2 - 3
spine-csharp/src/Atlas.cs

@@ -62,13 +62,12 @@ namespace Spine {
 			float invTexHeight = 1f / textureHeight;
 			String[] tuple = new String[4];
 
-			// Skip to first page entry.
+			// Skip past first page name.
 			while (true) {
 				String line = reader.ReadLine();
-				if (line.Trim().Length == 0)
+				if (line.Trim().Length != 0)
 					break;
 			}
-			reader.ReadLine(); // Skip first page name.
 
 			Format = (Format)Enum.Parse(typeof(Format), readValue(reader), false);