[epiphany/mcatanzaro/webextension-deinitialize] Remove ephy_web_process_extension_deinitialize
- From: Michael Catanzaro <mcatanzaro src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [epiphany/mcatanzaro/webextension-deinitialize] Remove ephy_web_process_extension_deinitialize
- Date: Wed, 3 Feb 2021 23:09:29 +0000 (UTC)
commit c23bc31831d24dc76d2fc30399010e6a8e1e7319
Author: Michael Catanzaro <mcatanzaro gnome org>
Date: Wed Feb 3 17:07:15 2021 -0600
Remove ephy_web_process_extension_deinitialize
dispose works fine.
embed/web-process-extension/ephy-web-process-extension-main.c | 6 +-----
embed/web-process-extension/ephy-web-process-extension.c | 8 ++------
2 files changed, 3 insertions(+), 11 deletions(-)
---
diff --git a/embed/web-process-extension/ephy-web-process-extension-main.c
b/embed/web-process-extension/ephy-web-process-extension-main.c
index 8f3298198..749bcf128 100644
--- a/embed/web-process-extension/ephy-web-process-extension-main.c
+++ b/embed/web-process-extension/ephy-web-process-extension-main.c
@@ -63,11 +63,7 @@ webkit_web_extension_initialize_with_user_data (WebKitWebExtension *webkit_exten
static void __attribute__((destructor))
ephy_web_process_extension_shutdown (void)
{
- if (extension) {
- ephy_web_process_extension_deinitialize (extension);
- g_object_unref (extension);
- }
-
+ g_clear_object (&extension);
ephy_settings_shutdown ();
ephy_file_helpers_shutdown ();
}
diff --git a/embed/web-process-extension/ephy-web-process-extension.c
b/embed/web-process-extension/ephy-web-process-extension.c
index de1cd6302..f7e92e476 100644
--- a/embed/web-process-extension/ephy-web-process-extension.c
+++ b/embed/web-process-extension/ephy-web-process-extension.c
@@ -396,6 +396,8 @@ ephy_web_process_extension_dispose (GObject *object)
g_clear_pointer (&extension->frames_map, g_hash_table_unref);
}
+ g_clear_pointer (&extension->translation_table, g_hash_table_destroy);
+
G_OBJECT_CLASS (ephy_web_process_extension_parent_class)->dispose (object);
}
@@ -823,9 +825,3 @@ ephy_web_process_extension_initialize (EphyWebProcessExtension *extension,
extension->translation_table = g_hash_table_new (g_str_hash, NULL);
}
-
-void
-ephy_web_process_extension_deinitialize (EphyWebProcessExtension *extension)
-{
- g_clear_pointer (&extension->translation_table, g_hash_table_destroy);
-}
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]