[epiphany/mcatanzaro/webapp-profile: 14/19] Fix ephy_config_dir() in web process



commit f205c84558576a43b77d210004cb348c8a65f2bf
Author: Michael Catanzaro <mcatanzaro igalia com>
Date:   Sun Mar 17 10:26:02 2019 -0500

    Fix ephy_config_dir() in web process
    
    The web process is creating its config dir (for storing its read-only
    keyfile view of Epiphany settings) in the wrong place, under
    ~/.local/share/epiphany/config instead of under ~/.config/epiphany.
    Problem is we take the codepath in ephy_file_helpers_init() for
    non-default profile dirs. We're supposed to pass NULL for the profile
    dir when we want the default dir, not pass the path to the default dir.

 embed/ephy-embed-shell.c                      | 4 ++--
 embed/web-extension/ephy-web-extension-main.c | 2 +-
 2 files changed, 3 insertions(+), 3 deletions(-)
---
diff --git a/embed/ephy-embed-shell.c b/embed/ephy-embed-shell.c
index 6f1c3591c..35d1a57cd 100644
--- a/embed/ephy-embed-shell.c
+++ b/embed/ephy-embed-shell.c
@@ -926,10 +926,10 @@ initialize_web_extensions (WebKitWebContext *web_context,
 
   private_profile = priv->mode == EPHY_EMBED_SHELL_MODE_PRIVATE || priv->mode == 
EPHY_EMBED_SHELL_MODE_INCOGNITO || priv->mode == EPHY_EMBED_SHELL_MODE_AUTOMATION;
   browser_mode = priv->mode == EPHY_EMBED_SHELL_MODE_BROWSER;
-  user_data = g_variant_new ("(smsssbb)",
+  user_data = g_variant_new ("(smsmssbb)",
                              priv->guid,
                              address,
-                             ephy_profile_dir (),
+                             ephy_profile_dir_is_default () ? NULL : ephy_profile_dir (),
                              ephy_filters_manager_get_adblock_filters_dir (priv->filters_manager),
                              private_profile,
                              browser_mode);
diff --git a/embed/web-extension/ephy-web-extension-main.c b/embed/web-extension/ephy-web-extension-main.c
index 8e37fb5cd..09f9e945f 100644
--- a/embed/web-extension/ephy-web-extension-main.c
+++ b/embed/web-extension/ephy-web-extension-main.c
@@ -42,7 +42,7 @@ webkit_web_extension_initialize_with_user_data (WebKitWebExtension *webkit_exten
   gboolean browser_mode;
   g_autoptr(GError) error = NULL;
 
-  g_variant_get (user_data, "(&sm&s&s&sbb)", &guid, &server_address, &profile_dir, &adblock_data_dir, 
&private_profile, &browser_mode);
+  g_variant_get (user_data, "(&sm&sm&s&sbb)", &guid, &server_address, &profile_dir, &adblock_data_dir, 
&private_profile, &browser_mode);
 
   if (!server_address) {
     g_warning ("UI process did not start D-Bus server, giving up.");


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]