PollHandler: Ensure that m_pollStartEvent is always initialized to null

Otherwise it may be undefined, and we DO create default-constructed
PollHandler. For example, one is used as a fallback poll object
in NeoChatRoom::poll.

This is blind fix for a pretty nasty poll-related crash we saw a few
months ago.

BUG: 493649
(cherry picked from commit 5ef66b5cf6)
This commit is contained in:
Joshua Goins
2024-11-09 18:45:38 -05:00
parent 43d40c7e75
commit 258312e798

View File

@@ -91,7 +91,7 @@ Q_SIGNALS:
void hasEndedChanged();
private:
const Quotient::PollStartEvent *m_pollStartEvent;
const Quotient::PollStartEvent *m_pollStartEvent = nullptr;
void updatePoll(Quotient::RoomEventsRange events);