mirror of
https://gitlab.gnome.org/GNOME/glib.git
synced 2025-02-23 10:42:11 +01:00
GWin32AppInfo: Fix g_str_has_prefix() check
Fixes https://gitlab.gnome.org/GNOME/glib/-/issues/2972
This commit is contained in:
parent
a1e169129c
commit
830bcbcf29
@ -4349,7 +4349,7 @@ expand_macro_single (char macro, file_or_uri *obj)
|
|||||||
const char *prefix = "file:///";
|
const char *prefix = "file:///";
|
||||||
const size_t prefix_len = strlen (prefix);
|
const size_t prefix_len = strlen (prefix);
|
||||||
|
|
||||||
if (g_str_has_prefix (obj->uri, prefix) == 0 && obj->uri[prefix_len] != 0)
|
if (g_str_has_prefix (obj->uri, prefix) && obj->uri[prefix_len] != 0)
|
||||||
{
|
{
|
||||||
GFile *file = g_file_new_for_uri (obj->uri);
|
GFile *file = g_file_new_for_uri (obj->uri);
|
||||||
result = g_file_get_path (file);
|
result = g_file_get_path (file);
|
||||||
|
Loading…
x
Reference in New Issue
Block a user