Created attachment 233424 [details] use "enoptions" resource name for unknown locales This is a follow up to https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=254702 running "env LANG=pl_PL.UTF-8 netsurf-gtk3 -v" : the browser starts fine, preferences windows does not open, the logfile says (9.232225) frontends/gtk/preferences.c:982 GtkWidget *nsgtk_preferences(struct browser_window *, GtkWindow *): Preferences UI builder init failed running "env LANG=fr_FR.UTF-8 netsurf-gtk3 -v" : the browser starts fine, the preferences window does open in French. I have traced this back to the issue with the patch for https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=254702: fallback UI resource name has been called "enoption" and not "enoptions". FreeBSD locale problems have been also reported https://bugs.netsurf-browser.org/mantis/view.php?id=2045 maybe our solution is worth upstreaming. I think the whole fix to the issue at hand is a bit shabby, maybe we could come up with something better. Quick fix attached.
A commit in branch main references this bug: URL: https://cgit.FreeBSD.org/ports/commit/?id=7f0f07a1e2b21fa2809ffd325e574aec73b64a57 commit 7f0f07a1e2b21fa2809ffd325e574aec73b64a57 Author: Marcin Cieślak <saper@saper.info> AuthorDate: 2022-04-28 18:23:54 +0000 Commit: Neel Chauhan <nc@FreeBSD.org> CommitDate: 2022-04-28 18:25:12 +0000 www/netsurf: Fix crash on preferences dialog with certain languages This happens with certain languages like pl_PL.UTF-8. PR: 263498 www/netsurf/Makefile | 2 +- www/netsurf/files/patch-frontends_gtk_preferences.c | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-)
Committed! Thanks for both your patches.