diff options
author | volzhs <volzhs@gmail.com> | 2016-12-22 09:54:15 +0900 |
---|---|---|
committer | volzhs <volzhs@gmail.com> | 2016-12-24 00:46:09 +0900 |
commit | e04c7e11ec2fabf34aaf515103bc0b6086e1aabd (patch) | |
tree | 7e8e1947eb71efe8bf45632610ee2776c9ef0b3e /thirdparty/libwebp/enc/histogram.c | |
parent | 2c8a1729152f5bcb1cb81d24b1e642634bff7174 (diff) | |
download | redot-engine-e04c7e11ec2fabf34aaf515103bc0b6086e1aabd.tar.gz |
Update libwebp to 0.5.2
Diffstat (limited to 'thirdparty/libwebp/enc/histogram.c')
-rw-r--r-- | thirdparty/libwebp/enc/histogram.c | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/thirdparty/libwebp/enc/histogram.c b/thirdparty/libwebp/enc/histogram.c index 395372b245..36b7f22625 100644 --- a/thirdparty/libwebp/enc/histogram.c +++ b/thirdparty/libwebp/enc/histogram.c @@ -592,8 +592,8 @@ static int HistoQueueInit(HistoQueue* const histo_queue, const int max_index) { histo_queue->max_size = max_index * max_index; // We allocate max_size + 1 because the last element at index "size" is // used as temporary data (and it could be up to max_size). - histo_queue->queue = WebPSafeMalloc(histo_queue->max_size + 1, - sizeof(*histo_queue->queue)); + histo_queue->queue = (HistogramPair*)WebPSafeMalloc( + histo_queue->max_size + 1, sizeof(*histo_queue->queue)); return histo_queue->queue != NULL; } @@ -659,7 +659,8 @@ static int HistogramCombineGreedy(VP8LHistogramSet* const image_histo) { int i, j; VP8LHistogram** const histograms = image_histo->histograms; // Indexes of remaining histograms. - int* const clusters = WebPSafeMalloc(image_histo_size, sizeof(*clusters)); + int* const clusters = + (int*)WebPSafeMalloc(image_histo_size, sizeof(*clusters)); // Priority queue of histogram pairs. HistoQueue histo_queue; |