[Fontconfig-bugs] [Bug 96535] New: Code obfuscation results in memory leaks reported by Valgrind, AddressSanitizer
bugzilla-daemon at freedesktop.org
bugzilla-daemon at freedesktop.org
Wed Jun 15 10:28:26 UTC 2016
https://bugs.freedesktop.org/show_bug.cgi?id=96535
Bug ID: 96535
Summary: Code obfuscation results in memory leaks reported by
Valgrind, AddressSanitizer
Product: fontconfig
Version: 2.11
Hardware: Other
OS: All
Status: NEW
Severity: normal
Priority: medium
Component: library
Assignee: fontconfig-bugs at lists.freedesktop.org
Reporter: zboszor at pr.hu
QA Contact: freedesktop at behdad.org
Fontconfig uses pointer arithmetics to compute the distance from an object base
pointer to a member structure and the result is stored in intptr_t type
members.
This causes reported memory leaks in fontconfig in applications compiled with
GCC's AddressSanitizer and Valgrind, too.
The fact that the size of intptr_t always equals to the size of a pointer makes
this whole thing look like code obfuscation.
It also slows down the code slightly. Pointer arithmetics and storing the
result is always slower than just storing the pointer value.
The amount of reported memory leaks in AddressSanitizer is so much that it
makes genuine debugging hard, like searching for a needle in a haystack.
Please, use real pointers instead of intptr_t.
--
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/fontconfig-bugs/attachments/20160615/aa7e719a/attachment.html>
More information about the Fontconfig-bugs
mailing list