Fix a segfault when the connection is dropped
The error dialog window was created on the "tick" thread, causing a crash in GTK. Fix it by moving its invocation to the main thread.
This commit is contained in:
parent
a6881c6ff1
commit
823c3b20b5
|
@ -291,8 +291,9 @@ class vmmEngine(vmmGObject):
|
|||
logging.debug("Closing connection since libvirtd "
|
||||
"appears to have stopped")
|
||||
else:
|
||||
self.err.show_err(_("Error polling connection '%s': %s") %
|
||||
(conn.get_uri(), e))
|
||||
error_msg = _("Error polling connection '%s': %s") \
|
||||
% (conn.get_uri(), e)
|
||||
self.idle_add(lambda: self.err.show_err(error_msg))
|
||||
|
||||
self.idle_add(conn.close)
|
||||
|
||||
|
|
Loading…
Reference in New Issue