diff --git a/libImaging/RankFilter.c b/libImaging/RankFilter.c index 84090f751..eb863ad97 100644 --- a/libImaging/RankFilter.c +++ b/libImaging/RankFilter.c @@ -81,6 +81,7 @@ ImagingRankFilter(Imaging im, int size, int rank) size * sizeof(type));\ IMAGING_PIXEL_##type(imOut, x, y) = Rank##type(buf, size2, rank);\ }\ + free(buf); \ } while (0) if (im->image8)