mirror of
https://github.com/python-pillow/Pillow.git
synced 2025-01-28 18:24:57 +03:00
Return ImagingError_MemoryError
This commit is contained in:
parent
fd4b0609ef
commit
15dd7aef9f
|
@ -54,7 +54,7 @@ ImagingHistogramNew(Imaging im)
|
||||||
h->histogram = calloc(im->pixelsize, 256 * sizeof(long));
|
h->histogram = calloc(im->pixelsize, 256 * sizeof(long));
|
||||||
if (h->histogram == NULL) {
|
if (h->histogram == NULL) {
|
||||||
free(h);
|
free(h);
|
||||||
return NULL;
|
return (ImagingHistogram) ImagingError_MemoryError();
|
||||||
}
|
}
|
||||||
|
|
||||||
return h;
|
return h;
|
||||||
|
|
Loading…
Reference in New Issue
Block a user