From 570a05a33c9dc42a16caa5a1a11cf34d4df1c1f9 Mon Sep 17 00:00:00 2001 From: Albrecht Schlosser Date: Mon, 21 Feb 2022 16:51:20 +0100 Subject: Fix compiler warning [-Wunused-but-set-variable] --- test/unittest_circles.cxx | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/test/unittest_circles.cxx b/test/unittest_circles.cxx index 9f919be60..b816a4b6d 100644 --- a/test/unittest_circles.cxx +++ b/test/unittest_circles.cxx @@ -40,7 +40,6 @@ void arc(int xi, int yi, int w, int h, double a1, double a2) int i, segs = circ * (a2-a1) / 100; if (segs<3) segs = 3; - int px, py; a1 = a1/180*M_PI; a2 = a2/180*M_PI; double step = (a2-a1)/segs; @@ -49,11 +48,9 @@ void arc(int xi, int yi, int w, int h, double a1, double a2) int ny = y - sin(a1)*ry; fl_point(nx, ny); for (i=segs; i>0; i--) { - a1+=step; - px = nx; py = ny; + a1 += step; nx = x + cos(a1)*rx; ny = y - sin(a1)*ry; - //fl_line(px, py, nx, ny); fl_point(nx, ny); } } -- cgit v1.2.3