Close the pixbufloader in all cases. Fixes gtk warnings in console.
This commit is contained in:
parent
5f797834ae
commit
bcbcc98b06
|
@ -396,6 +396,7 @@ def get_pixbuf_from_data(file_data, want_type = False):
|
|||
pixbufloader.close()
|
||||
pixbuf = pixbufloader.get_pixbuf()
|
||||
except gobject.GError: # 'unknown image format'
|
||||
pixbufloader.close()
|
||||
pixbuf = None
|
||||
if want_type:
|
||||
return None, None
|
||||
|
|
Loading…
Reference in New Issue