From ae11e18cbd274a7f20d977aa38de6534c32b60a0 Mon Sep 17 00:00:00 2001 From: Alexei Podtelezhnikov Date: Wed, 15 Jan 2025 15:50:12 +0000 Subject: [PATCH] * src/bdf/bdflib.c (bdf_add_property_): Add extra protection. See https://issues.oss-fuzz.com/issues/389972472 https://issues.oss-fuzz.com/issues/389968131 --- src/bdf/bdflib.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/bdf/bdflib.c b/src/bdf/bdflib.c index e072ca432..a449b88d2 100644 --- a/src/bdf/bdflib.c +++ b/src/bdf/bdflib.c @@ -1085,7 +1085,8 @@ /* First, check whether the property already exists in the font. */ - if ( ( propid = ft_hash_str_lookup( name, font->internal ) ) != NULL ) + if ( font->props_used && + ( propid = ft_hash_str_lookup( name, font->internal ) ) != NULL ) { /* The property already exists in the font, so simply replace */ /* the value of the property with the current value. */