telegramdesktop/tdesktop/dev • 24ccd1c • 1 files, +6/-1 Fix crash when finishing the appearing text

Telegram github commits and releases

Telegram github commits and releases

@tgappsupdates

Broadcast from the most important Telegram clients' repositories

4,538 subscribers
Open in Telegram
telegramdesktop/tdesktop/dev24ccd1c1 files, +6/-1
Fix crash when finishing the appearing text animation

textAppearCheckLine() runs synchronously from inside the width and
height animation tick callbacks (textAppearWidthCallback /
textAppearHeightCallback). Calling RemoveComponents(TextAppearing::Bit())
there destroys those very animations (and their Ui::Animations::Simple
data) while the animations manager is still iterating them, leading to a
use-after-free / null _data dereference in Simple::value().

Defer the component removal to the next main loop iteration so the
running tick can unwind first.

#tdesktop
Open post in Telegram