mirror of
https://github.com/python-pillow/Pillow.git
synced 2025-07-05 04:13:11 +03:00
Fix leak of destination image in ImagingUnsharpMask when an error occurs
This commit is contained in:
parent
eaab435403
commit
a9bcd7db88
|
@ -2226,6 +2226,7 @@ _unsharp_mask(ImagingObject *self, PyObject *args) {
|
|||
}
|
||||
|
||||
if (!ImagingUnsharpMask(imOut, imIn, radius, percent, threshold)) {
|
||||
ImagingDelete(imOut);
|
||||
return NULL;
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue
Block a user