mirror of
https://github.com/storytold/harfbuzz.git
synced 2026-11-28 17:19:17 +01:00
fixed leaks in CFF subr subset
This commit is contained in:
1 parent
85f5644e8e
commit
b721fdae66
2 files changed
+18
-2
No files matched your search
@@ -62,8 +62,13 @@ struct code_pair
|
||||
};
|
||||
|
||||
typedef hb_vector_t<char, 1> StrBuff;
|
||||
struct StrBuffArray : hb_vector_t<StrBuff>
|
||||
struct StrBuffArray : hb_vector_t<StrBuff>
|
||||
{
|
||||
inline void fini (void)
|
||||
{
|
||||
SUPER::fini_deep ();
|
||||
}
|
||||
|
||||
inline unsigned int total_size (void) const
|
||||
{
|
||||
unsigned int size = 0;
|
||||
@@ -71,6 +76,9 @@ struct StrBuffArray : hb_vector_t<StrBuff>
|
||||
size += (*this)[i].len;
|
||||
return size;
|
||||
}
|
||||
|
||||
private:
|
||||
typedef hb_vector_t<StrBuff> SUPER;
|
||||
};
|
||||
|
||||
/* CFF INDEX */
|
||||
|
||||
@@ -465,11 +465,19 @@ struct ParsedCStrs : hb_vector_t<ParsedCStr>
|
||||
{
|
||||
inline void init (unsigned int len_ = 0)
|
||||
{
|
||||
hb_vector_t<ParsedCStr>::init ();
|
||||
SUPER::init ();
|
||||
resize (len_);
|
||||
for (unsigned int i = 0; i < len; i++)
|
||||
(*this)[i].init ();
|
||||
}
|
||||
|
||||
inline void fini (void)
|
||||
{
|
||||
SUPER::fini_deep ();
|
||||
}
|
||||
|
||||
private:
|
||||
typedef hb_vector_t<ParsedCStr> SUPER;
|
||||
};
|
||||
|
||||
struct SubrSubsetParam
|
||||
|
||||
Reference in new issue
Block a user