shithub: pokecrystal

Download patch

ref: e3565bd7007b194b04ceecaf1909fff65062211f
parent: b5e0efc1182db878085f5d5bff99a0c7d94f88aa
author: yenatch <[email protected]>
date: Fri May 17 23:26:06 EDT 2013

gfx: safer alternating-byte detection in compression

--- a/extras/gfx.py
+++ b/extras/gfx.py
@@ -467,7 +467,7 @@
 		num_alts = 0
 
 		# make sure we don't check for alts at the end of the file
-		if self.address+2 >= self.end: return False
+		if self.address+3 >= self.end: return False
 
 		self.alts.append(self.byte)
 		self.alts.append(ord(self.image[self.address+1]))