forked from Silverfish/proton-bridge
Fix panic during restarting the bridge
This commit is contained in:
@ -208,7 +208,11 @@ func (s *FrontendQt) watchEvents() {
|
||||
s.Qml.ShowWindow()
|
||||
case <-restartBridgeCh:
|
||||
s.Qml.SetIsRestarting(true)
|
||||
s.App.Quit()
|
||||
// watchEvents is started in parallel with the Qt app.
|
||||
// If the event comes too early, app doesn't have to be ready yet.
|
||||
if s.App != nil {
|
||||
s.App.Quit()
|
||||
}
|
||||
case address := <-addressChangedCh:
|
||||
s.Qml.NotifyAddressChanged(address)
|
||||
case address := <-addressChangedLogoutCh:
|
||||
|
||||
Reference in New Issue
Block a user