From 425da0ed8a57fe8a0585a066bd82338f10430040 Mon Sep 17 00:00:00 2001 From: Andrew Murray Date: Sat, 18 Apr 2026 19:25:52 +1000 Subject: [PATCH] Check annotate_hash_table return value --- src/libImaging/Quant.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/libImaging/Quant.c b/src/libImaging/Quant.c index 7e3df180823..0e88a388a9c 100644 --- a/src/libImaging/Quant.c +++ b/src/libImaging/Quant.c @@ -1375,7 +1375,9 @@ quantize( fflush(stdout); timer = clock(); #endif - annotate_hash_table(root, h, &nPaletteEntries); + if (!annotate_hash_table(root, h, &nPaletteEntries)) { + goto error_3; + } #ifdef DEBUG printf("done (%f)\n", (clock() - timer) / (double)CLOCKS_PER_SEC); #endif