svg_loader: race condition on arc processing
authorMichal Maciola <m.maciola@samsung.com>
Tue, 13 Jul 2021 12:28:52 +0000 (14:28 +0200)
committerHermet Park <chuneon.park@samsung.com>
Wed, 14 Jul 2021 05:59:51 +0000 (14:59 +0900)
Unneeded static keyword in _pathAppendArcTo function led to race
conditioning
@issue: #604

Change-Id: I1741b56f6cf210b7709f513aceb657840851b3bf

src/loaders/svg/tvgSvgPath.cpp

index 1c8538f..b73d132 100644 (file)
@@ -207,7 +207,7 @@ void _pathAppendArcTo(Array<PathCommand>* cmds, Array<Point>* pts, Point* cur, P
         float theta2 = theta1 + delta;
         float cosTheta2 = cos(theta2);
         float sinTheta2 = sin(theta2);
-        static Point p[3];
+        Point p[3];
 
         //First control point (based on start point sx,sy)
         c1x = sx - bcp * (cosPhiRx * sinTheta1 + sinPhiRy * cosTheta1);