Bug 798845 - User Config and User Data link broken

On Mac's, the link does not work due to a space in the path like...
file:///Users/<username>/Library/Application Support/GnuCash

Fixed by escaping the path.
This commit is contained in:
Robert Fewell 2023-04-14 10:17:06 +01:00
parent 0c83c74532
commit 96c8cb738c

View File

@ -5165,7 +5165,9 @@ static gboolean
link_button_cb (GtkLinkButton *button, gpointer user_data)
{
const gchar *uri = gtk_link_button_get_uri (button);
gnc_launch_doclink (GTK_WINDOW(user_data), uri);
gchar *escaped_uri = g_uri_escape_string (uri, ":/.\\", true);
gnc_launch_doclink (GTK_WINDOW(user_data), escaped_uri);
g_free (escaped_uri);
return TRUE;
}