Use ImageFile.MAXBLOCK when saving TIFF images by radarhere · Pull Request #8461 · python-pillow/Pillow

Addresses an 'undone' that has been present since #98

# undone, change to self.decodermaxblock:
errcode, data = encoder.encode(16 * 1024)[1:]

self.decodermaxblock isn't necessarily available, because im may not be an ImageFile instance, but ImageFile.MAXBLOCK is usually the same.

self.decodermaxblock = MAXBLOCK