svg_loader: fill and stroke paiint url were copied twice 53/289753/1
authorMira Grudzinska <m.grudzinska@samsung.com>
Sun, 28 Aug 2022 21:45:29 +0000 (23:45 +0200)
committerMichal Szczecinski <mihashco89@gmail.com>
Tue, 14 Mar 2023 06:42:27 +0000 (07:42 +0100)
The url were copied in the _copyAttr and in the _styleCopy
functions.

Change-Id: Ia68f3f4be8c68e4be517d1376e0cf68e1d468bcc

src/loaders/svg/tvgSvgLoader.cpp

index 00c0911..3b3183d 100644 (file)
@@ -1992,8 +1992,6 @@ static void _copyAttr(SvgNode* to, const SvgNode* from)
     //Copy style attribute
     _styleCopy(to->style, from->style);
     to->style->flags = (SvgStyleFlags)((int)to->style->flags | (int)from->style->flags);
-    if (from->style->fill.paint.url) to->style->fill.paint.url = strdup(from->style->fill.paint.url);
-    if (from->style->stroke.paint.url) to->style->stroke.paint.url = strdup(from->style->stroke.paint.url);
     if (from->style->clipPath.url) to->style->clipPath.url = strdup(from->style->clipPath.url);
     if (from->style->mask.url) to->style->mask.url = strdup(from->style->mask.url);