commit: d14184648441aa1f90907c10f1a18d9087df5a7b
parent 6b89da092c97bad532a42c8c9cbb9c075f06d1f4
Author: Haelwenn (lanodan) Monnier <contact@hacktivis.me>
Date: Sun, 16 Jul 2023 03:58:07 +0200
Don't change URI on WebProcess termination
Diffstat:
1 file changed, 7 insertions(+), 0 deletions(-)
diff --git a/badwolf.c b/badwolf.c
@@ -119,6 +119,13 @@ WebViewCb_notify__uri(WebKitWebView *UNUSED(webView), GParamSpec *UNUSED(pspec),
struct Client *browser = (struct Client *)user_data;
location_uri = webkit_web_view_get_uri(browser->webView);
+ printf("location_uri: <%s>\n", location_uri);
+
+ // Don't set if location_uri is NULL / empty, latter happens on WebProcess termination
+ if(location_uri == NULL || location_uri[0] == '\0')
+ {
+ return TRUE;
+ }
gtk_entry_set_text(GTK_ENTRY(browser->location), location_uri);