Commit e7f0bc8c authored by Andrey Utkin's avatar Andrey Utkin Committed by Anton Khirnov

drawtext: add missing braces around an if() block.

Prevents uninitialized read.
Signed-off-by: 's avatarAnton Khirnov <anton@khirnov.net>
parent 86b57e4e
......@@ -492,9 +492,11 @@ static int dtext_prepare_text(AVFilterContext *ctx)
/* get glyph */
dummy.code = code;
glyph = av_tree_find(dtext->glyphs, &dummy, glyph_cmp, NULL);
if (!glyph)
if (!glyph) {
ret = load_glyph(ctx, &glyph, code);
if (ret) return ret;
if (ret)
return ret;
}
y_min = FFMIN(glyph->bbox.yMin, y_min);
y_max = FFMAX(glyph->bbox.yMax, y_max);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment