logo

badwolf

minimalist and privacy-oriented web browser based on WebKitGTK git clone https://hacktivis.me/git/badwolf.git
commit: 807f3221818d8f1dd703e6f09eabfc7da1f3ae8d
parent d14184648441aa1f90907c10f1a18d9087df5a7b
Author: Haelwenn (lanodan) Monnier <contact@hacktivis.me>
Date:   Sun, 16 Jul 2023 03:58:52 +0200

Don't change Title on WebProcess termination

Diffstat:

Mbadwolf.c8++++++++
1 file changed, 8 insertions(+), 0 deletions(-)

diff --git a/badwolf.c b/badwolf.c @@ -204,6 +204,14 @@ WebViewCb_notify__title(WebKitWebView *UNUSED(webView), { struct Client *browser = (struct Client *)user_data; + // Don't set if title is NULL / empty, latter happens on WebProcess crash + char *title = webkit_web_view_get_title(browser->webView); + printf("title: <%s>\n", title); + if(title == NULL || title[0] == '\0') + { + return TRUE; + } + webView_tab_label_change(browser, NULL); return TRUE;