You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Attempting to open a non-image file and catching the IOError causes the file handle to be left open, meaning this file cannot be modified by the process/os until the application stops.
Example code:
from PIL import Image
import os
path = '/path/to/non/image'
try:
Image.open(path)
except IOError as err:
print 'This is not an image file'
os.remove(path)
I am running Pillow 3.1.1 on Python 2.7.6
This should be fixable by calling fp.close() before raising the IOError in Image.open
The text was updated successfully, but these errors were encountered:
Attempting to open a non-image file and catching the IOError causes the file handle to be left open, meaning this file cannot be modified by the process/os until the application stops.
Example code:
I am running Pillow 3.1.1 on Python 2.7.6
This should be fixable by calling fp.close() before raising the IOError in Image.open
The text was updated successfully, but these errors were encountered: