[Poppler-bugs] [Bug 107151] Add font color in Poppler

bugzilla-daemon at freedesktop.org bugzilla-daemon at freedesktop.org
Thu Aug 16 11:40:44 UTC 2018


https://bugs.freedesktop.org/show_bug.cgi?id=107151

--- Comment #26 from Tobias Deiminger <haxtibal at posteo.de> ---
(In reply to Albert Astals Cid from comment #22)
> * GooString *fontTag;
>   parseAppearanceString(appearanceString, fontsize, fontcolor, fontTag);
> Is this a memory leak?

If you mean fontTag:
parseAppearanceString allocates fontTag, DefaultAppearance Ctor makes a copy,
and the very next line to DefaultAppearance Ctor is "delete fontTag".

If you mean fontcolor:
parseAppearanceString allocates fontcolor, DefaultAppearance takes ownership
and DefaultAppearance::~DefaultAppearance will eventually care for deletion.

The latter is leaky in conjunction with the copy-Ctor issue you mentioned, we
have to fix that. Besides that I don't see a leak, am I missing something?

-- 
You are receiving this mail because:
You are the assignee for the bug.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.freedesktop.org/archives/poppler-bugs/attachments/20180816/794678c2/attachment.html>


More information about the Poppler-bugs mailing list