mirror of
https://gitlab.gnome.org/GNOME/glib.git
synced 2024-12-27 07:56:14 +01:00
Fix translation from GIO's file attr to xattr attributes
Bug 579862 – requesting xattr::foo ends up calling getxattr(..., user.:foo,...) The patch makes sure we escape xattr::, not xattr:, before adding user. and calling getxattr.
This commit is contained in:
parent
a9c33dbd7a
commit
491a036d84
@ -527,7 +527,7 @@ get_xattrs (const char *path,
|
|||||||
attr2 = strchr (attr, ':');
|
attr2 = strchr (attr, ':');
|
||||||
if (attr2)
|
if (attr2)
|
||||||
{
|
{
|
||||||
attr2++; /* Skip ':' */
|
attr2 += 2; /* Skip '::' */
|
||||||
unescaped_attribute = hex_unescape_string (attr2, NULL, &free_unescaped_attribute);
|
unescaped_attribute = hex_unescape_string (attr2, NULL, &free_unescaped_attribute);
|
||||||
if (user)
|
if (user)
|
||||||
a = g_strconcat ("user.", unescaped_attribute, NULL);
|
a = g_strconcat ("user.", unescaped_attribute, NULL);
|
||||||
|
Loading…
Reference in New Issue
Block a user