[epiphany] window: Fix regression from the tab close rework
- From: Michael Catanzaro <mcatanzaro src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [epiphany] window: Fix regression from the tab close rework
- Date: Mon, 4 Feb 2019 02:08:57 +0000 (UTC)
commit e88860e46ae7fde72fced9bc3bbde37657dff048
Author: Michael Catanzaro <mcatanzaro igalia com>
Date: Sun Feb 3 20:07:32 2019 -0600
window: Fix regression from the tab close rework
If data->id == 0 then it's not a valid source and we shouldn't try to
remove it.
src/ephy-window.c | 6 ++++--
1 file changed, 4 insertions(+), 2 deletions(-)
---
diff --git a/src/ephy-window.c b/src/ephy-window.c
index 5d7bb72e8..b3893bf31 100644
--- a/src/ephy-window.c
+++ b/src/ephy-window.c
@@ -2774,8 +2774,10 @@ tab_has_modified_forms_cb (EphyWebView *view,
has_modified_forms = ephy_web_view_has_modified_forms_finish (view, result, NULL);
- /* Cancel timer so it doesn't close while waiting for the user. */
- g_source_remove (data->id);
+ if (data->id != 0) {
+ /* Ensure tab doesn't close while waiting for the user. */
+ g_source_remove (data->id);
+ }
if (data->id != 0 &&
data->window != NULL &&
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]