mirror of
https://github.com/python-pillow/Pillow.git
synced 2025-01-13 18:56:17 +03:00
Replaced flush try except with hasattr
This commit is contained in:
parent
8d3b240096
commit
384d32969d
|
@ -397,10 +397,8 @@ def _save(im, fp, filename, save_all=False):
|
||||||
|
|
||||||
fp.write(b";") # end of file
|
fp.write(b";") # end of file
|
||||||
|
|
||||||
try:
|
if hasattr(fp, "flush"):
|
||||||
fp.flush()
|
fp.flush()
|
||||||
except:
|
|
||||||
pass
|
|
||||||
|
|
||||||
|
|
||||||
def get_interlace(im):
|
def get_interlace(im):
|
||||||
|
|
Loading…
Reference in New Issue
Block a user