From 570fe998c942e1042c66bbab2f848a9e05ad777a Mon Sep 17 00:00:00 2001 From: Behdad Esfahbod Date: Wed, 25 Jan 2023 15:42:24 -0700 Subject: [PATCH] [cairo] Another sweep_gradient fix k was -1 sometimes. Fixes the rest of https://roettsch.es/var_colrv1.html --- src/hb-cairo-utils.cc | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/hb-cairo-utils.cc b/src/hb-cairo-utils.cc index 3466cba79..299fdbebf 100644 --- a/src/hb-cairo-utils.cc +++ b/src/hb-cairo-utils.cc @@ -727,7 +727,7 @@ _hb_cairo_add_sweep_gradient_patches (hb_color_stop_t *stops, //assert (angles[0] + k * span <= 0 && 0 < angles[n_stops - 1] + k * span); span = fabs (span); - for (unsigned l = k; l < 1000; l++) + for (signed l = k; l < 1000; l++) { for (unsigned i = 1; i < n_stops; i++) {