]> granicus.if.org Git - graphviz/commitdiff
genEllipticPath: remove shadowing of 'etaB' variable
authorMatthew Fernandez <matthew.fernandez@gmail.com>
Sun, 29 Aug 2021 19:33:08 +0000 (12:33 -0700)
committerMatthew Fernandez <matthew.fernandez@gmail.com>
Sat, 4 Sep 2021 03:28:42 +0000 (20:28 -0700)
lib/common/ellipse.c

index 66c4d8912a5aace970e19b655745495709f35990..97c0dfa209e17b35750548180b8e522b6bcce269 100644 (file)
@@ -471,12 +471,12 @@ static Ppolyline_t *genEllipticPath(ellipse_t * ep) {
     while (!found && n < 1024) {
        double diffEta = (ep->eta2 - ep->eta1) / n;
        if (diffEta <= 0.5 * M_PI) {
-           double etaB = ep->eta1;
+           double etaOne = ep->eta1;
            found = true;
            for (i = 0; found && i < n; ++i) {
-               double etaA = etaB;
-               etaB += diffEta;
-               found = estimateError(ep, DEGREE, etaA, etaB) <= THRESHOLD;
+               double etaA = etaOne;
+               etaOne += diffEta;
+               found = estimateError(ep, DEGREE, etaA, etaOne) <= THRESHOLD;
            }
        }
        n = n << 1;