mirror of
https://github.com/ddnet/ddnet.git
synced 2024-09-20 01:24:18 +00:00
Merge #2260
2260: Fix out of bounds read r=def- a=Learath2 @Jupeyy I'm not completely familiar with the text rendering code but I think it needs a large rework. The code isn't concise or easy to read, the interface is horrendous. e.g. That `MaxWidth` parameter on `DoLabel` is an integer and it's used completely wrongly leading to a out of bounds read. Co-authored-by: Learath <learath2@gmail.com>
This commit is contained in:
commit
18f5ae442a
|
@ -912,7 +912,7 @@ void CMenus::RenderNews(CUIRect MainView)
|
|||
else
|
||||
{
|
||||
MainView.HSplitTop(20.0f, &Label, &MainView);
|
||||
UI()->DoLabelScaled(&Label, aLine, 15.f, -1, MainView.w-30.0f);
|
||||
UI()->DoLabelScaled(&Label, aLine, 15.f, -1, -1);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue