mirror of
https://github.com/storytold/harfbuzz.git
synced 2026-11-29 01:23:56 +01:00
Fix check_struct to check min_size instead of sizeof
This commit is contained in:
1 parent
ed07422c33
commit
54842374c2
1 file changed
+1
-1
@@ -243,7 +243,7 @@ struct hb_sanitize_context_t
|
||||
template <typename Type>
|
||||
inline bool check_struct (const Type *obj) const
|
||||
{
|
||||
return likely (this->check_range (obj, sizeof (*obj)));
|
||||
return likely (this->check_range (obj, obj->min_size));
|
||||
}
|
||||
|
||||
inline bool can_edit (const void *base HB_UNUSED, unsigned int len HB_UNUSED)
|
||||
|
||||
Reference in new issue
Block a user