Commit 271ae93d authored by Ray Strode's avatar Ray Strode

Make gs_window_cancel_unlock_request synchronous

This way we know the cancel has finished before moving
on in the code.

Part of fix for
https://bugzilla.gnome.org/show_bug.cgi?id=609789
parent f93a22c1
......@@ -1023,20 +1023,7 @@ gs_window_destroy (GSWindow *window)
{
g_return_if_fail (GS_IS_WINDOW (window));
if (window->priv->lock_pid > 0) {
gs_window_dialog_finish (window);
}
remove_popup_dialog_idle (window);
remove_command_watches (window);
remove_watchdog_timer (window);
if (window->priv->lock_box != NULL) {
gtk_container_remove (GTK_CONTAINER (window->priv->vbox), GTK_WIDGET (window->priv->lock_box));
window->priv->lock_box = NULL;
g_signal_emit (window, signals [DIALOG_DOWN], 0);
}
gs_window_cancel_unlock_request (window);
gtk_widget_destroy (GTK_WIDGET (window));
}
......@@ -1765,7 +1752,18 @@ gs_window_cancel_unlock_request (GSWindow *window)
}
if (window->priv->lock_pid > 0) {
kill (window->priv->lock_pid, SIGTERM);
gs_window_dialog_finish (window);
}
remove_popup_dialog_idle (window);
remove_command_watches (window);
remove_watchdog_timer (window);
if (window->priv->lock_box != NULL) {
gtk_container_remove (GTK_CONTAINER (window->priv->vbox), GTK_WIDGET (window->priv->lock_box));
window->priv->lock_box = NULL;
g_signal_emit (window, signals [DIALOG_DOWN], 0);
}
}
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment