From e7c1c43e27206f20861e5e4617e89a0fdf09d9c8 Mon Sep 17 00:00:00 2001 From: Ozkan Sezer Date: Thu, 23 Nov 2023 05:40:32 +0300 Subject: [PATCH] nanosvgrast.h: update from mainstream --- src/nanosvgrast.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/nanosvgrast.h b/src/nanosvgrast.h index 2947b100..9531bb4c 100644 --- a/src/nanosvgrast.h +++ b/src/nanosvgrast.h @@ -1290,7 +1290,7 @@ static void nsvg__initPaint(NSVGcachedPaint* cache, NSVGpaint* paint, float opac if (grad->nstops == 0) { for (i = 0; i < 256; i++) cache->colors[i] = 0; - } if (grad->nstops == 1) { + } else if (grad->nstops == 1) { for (i = 0; i < 256; i++) cache->colors[i] = nsvg__applyOpacity(grad->stops[i].color, opacity); } else {