0

properly loads the image and detects corrupted images

This commit is contained in:
Andrew Brown
2010-09-25 15:07:41 -04:00
parent 3c75c60f61
commit 8d2c575758

View File

@@ -532,6 +532,7 @@ def render_worldtile(chunks, colstart, colend, rowstart, rowend, path):
for col, row, chunkfile in chunks: for col, row, chunkfile in chunks:
try: try:
chunkimg = Image.open(chunkfile) chunkimg = Image.open(chunkfile)
chunkimg.load()
except IOError, e: except IOError, e:
print "Error opening file", chunkfile print "Error opening file", chunkfile
print "Attempting to re-generate it..." print "Attempting to re-generate it..."