[mythtv-commits] [MythTV/mythtv] a2cf26: Check instance before starting EnableUDPListener
noreply at github.com
Tue Jun 22 17:16:38 UTC 2021
Author: Klaas de Waal <kdewaal at mythtv.org>
Date: 2021-06-22 (Tue, 22 Jun 2021)
Check instance before starting EnableUDPListener
When the database setting StartupScreenDelay is changed from 0 to another value
outside of mythfrontend, e.g. with manual sql commands or by switching to a restored
database, mythtv-setup and mythfrontend do crash after briefly showing the setup screen.
This is now fixed by checking both the thread and the instance pointer before
calling EnableUDPListener. If the check fails an error message is given.
As to why this happens, this is the bit of code around mythcontext.cpp:1652:
d->m_settingsCacheDirty = false;
This bit of code is called when the setup screen is pulled down and before
the real main winow is created.
The DestroyMythMainWindow does delete the MythUDPListener instance.
The MythUDPListener is static which means it is never created again, causing
the creation of the real main window to fail when the UPDListener is started.
More information about the mythtv-commits