@contextmanager<EOL>def image_save_buffer_fix(maxblock=<NUM_LIT>):
before = ImageFile.MAXBLOCK<EOL>ImageFile.MAXBLOCK = maxblock<EOL>try:<EOL><INDENT>yield<EOL><DEDENT>finally:<EOL><INDENT>ImageFile.MAXBLOCK = before<EOL><DEDENT>
Contextmanager that change MAXBLOCK in ImageFile.